I thought I was done after the first hour until I ran CCC’s test cases. Turns out I lacked a SINGLE but necessary test case that I didn’t write.
This is much more interesting case study of TDD and how skipping a step ahead can mess you up tremendously.
Problem
Given a list of jerseys with num...
Today is the first problem from CCC 2015. You’ll see quite a few code problems from there in the future. I noticed the CCC problem set tends to over complicate the problem description. Allow me to restate it in a much simpler, clearer, and easier to understand version.
Summary of Zero That Out:...
This kata comes from here.
I realized doing this post after the code was written is quite difficult, as a lot of the juicy details stuff got refactored away. So please ask me if you don’t understand any section!
Premise:
Given a bunch of items, their price per item, and a special bulk discount...