Fizzbuzz kata
Will spent some time with me and Megan doing pair programming of the Fizzbuzz kata using TDD (Test Driven Development). We had to write a failing test first (in Cucumber). Then make it pass. Megan and I took turns. Here is the rules for Fizzbuzz:
- If it’s a multiple of 3, then say “Fizz”
- if it’s a multiple of 5, then say “Buzz”
- if it’s a multiple of 3 and 5, then say “Fizzbuzz”
- if none of these apply, then say the say the input number.
We got it working in short order. Megan had trouble with her arrow keys in vim. It was working but now it is doing funky things like putting “A” and “B” and ruining her cursor position. It turned out that she had
The directive was eating up the escape so that the escape sequence generated by the arrow keys are being consumed and leaving the rest of the sequence to appear on the screen. We changed it to
and everything is working fine.