Back in May, I decided to write down my tips and tricks of the month. My hope is that people find them useful (or share even newer tricks for me), but at the very least, writing them down organizes my thoughts (and forces me to write a blog post more than once a year). So here’s what I got for June:
span:nth-child isn’t the nth span (6/22/20)
Shame on me again for not reading docs first.
If I have a CSS rule that specifies `span:nth-child(2n)` (or every 2nd one), it won’t give me the span with id 2 and 4, it will give me the span with 2 and 3! This is because nth-child refers to the sibling group, which is all the elements. From there it finds every second sibling, and then if that sibling is a span, does it apply the styling.
So I’ve decided to do Advent of Code this year again (no surprise there), but this time, I’m encouraging everyone in HSV.py to join me as well.
I’ve completed 8 challenges, and thought it was time for a recap. I plan on breaking down solutions day by day, and then ending with some lessons learned that might help others. I compete each night with ugly hacked together code, then work on refactoring it the next day. What I share is the refactored version (Don’t think I spit something like this out in just an hour). You can find all my code on my GitHub
So let’s get started.
Advent Of Code 2016 – Day 1
SPOILER ALERT: If you have any inkling, any whatsoever, to work on the Advent of Code…. DO NOT READ THIS BLOG POST. DO NOT LOOK AT MY GITHUB PROJECT. It is no fun if you’re not solving it yourself, and you’ll feel so much better about yourself if you can figure it out without looking up an answer. This blog post is not to give away the answer, but instead, is there for people to learn from.
As always, the following code is in my GitHub:
The problem started off simple enough. There is a 9 digit keypad listed:
If you start at the 5 key, and are given directions to move up, down, right or left, multiple times, what are the keys that you end at after each iteration of directions?
Not too bad, and I was picking a language in my wheelhouse, Python. I chose Python 3, since I don’t get much experience with it, but unfortunately, this program did not stretch my knowledge of Python 3. There wasn’t enough meat to the problem to really dive in.
So let’s look at the code:
So a few days ago, I officially submitted my first conference talk! Bdd to the Bone: Test-Driving Web Applications with Behave and Selenium. It’s no secret that testing is close to my heart as far as software enginnering goes, so I wanted to give a talk representing some of my interests. I want to talk about some of the things that went through my head on this.