In our next practice session, we need to build a class that will automatically translate a number into its roman numeral counterpart. As with the previous episode, we'll use TDD and PHPSpec to drive this process.
Homework: what would happen if the user passed 0 to our converter? Shouldn't we take exception to that? On your own, implement this functionality using TDD.
View the source for this lesson (and the homework solution) on GitHub.
In this code kata, we need to recreate the scoring system for a game of bowling. Does that sound tough? How do we deal with scoring spares, or strikes, or multiple strikes!? Well, if we use TDD to work toward our goal, it shouldn't be too tough. Let's dig in.
View the source for this kata on GitHub.
Now that you've worked your way through a number of code kata challenges, let's review the obligatory FizzBuzz exercise, and learn just how easy it is to solve.
In this lesson, we'll tackle the intimidating Gilded Rose kata in PHP. Our job is to translate a monstrously confusing set of countless conditionals into a small series of readable methods. Work along with this lesson, and you'll benefit greatly.
View the slightly altered setup and solution (see second branch) for this lesson on GitHub.