What I should have done last night was a hard coding challenge. Instead, I spent way too many hours trying to clean up an easy challenge to get a full score. The challenge itself wasn’t hard, but getting it to not suck up time and memory was difficult. What’s worse, figuring out how to test it so every contingency was covered left me in a nightmare spiral that consumed hours of Tuesday evening and early Wednesday morning. Instead of taking a step back and reassessing the problem, I just kept trying to patch over the holes. The code kept getting uglier and uglier, and yet I pushed on. And in the end, I scrapped all of the code and have decided to start over with it.
Once I took the steps to get out of that mess (at least for the time being) the rest of the day went better. I made it through five easy challenges (three PHP, one Ruby, one Python) and a moderate PHP challenge. One of the challenges involved regex (regular expressions), which are a wonderful thing to deal with on top of the languages themselves. Regex would be useless if it wasn’t so useful.
Latest posts by Andrew (see all)
- On Developers and Von Moltke’s Leadership Matrix - November 9, 2015
- Andrew’s Coding Corner- Beware the Sunk Cost Fallacy - November 3, 2015
- Andrew’s Coding Corner – Unit Test, Young Man, and Grow Up With the Code - October 27, 2015