I was doing some code katas last week and it suddenly dawned up on me how awesome data structures and algorithms problems are to practice TDD. They provide such a well defined problem space and expected API that you can fully concentrate in the red-green-refactor flow until it becomes second nature. One pass and you focus on the red-green-refactor, another pass and you can improve your knowledge of jasmine, another and you focus on sinon, another and you try to improve your abstractions, another and you concentrate on writing the most readable of tests, and so on until eternity :)
Not interested in practicing TDD? Don’t panic! You can use any of these exercises to practice other stuff, becoming more proficient and productive using your favorite IDE or text editor, learn new ReSharper shortcuts, new vim commands, functional programming, other languages, etc. Just decide what you want to practice in each session and be awesome.
And here are some other places where you can find lots of different exercises and katas:
Written by Jaime González García , Dad, Husband, Front-end software engineer, UX designer, amateur pixel artist, tinkerer and master of the arcane arts. You should follow him on Twitter where he shares useful stuff! (and is funny too).Follow @vintharas