Exercise 1.1

You are going to write a function “Say” with input of integer and output of string. The function return the integer itself except these numbers:

Here are sample outputs from the input 1 to 15:

1  
2  
Fizz  
4  
Buzz  
Fizz  
7  
8  
Fizz  
Buzz  
11  
Fizz  
13  
14  
FizzBuzz  
...

Please try implement this function in TDD way. Do not look for the solution on the internet before you try on your own. Different developers might come up with different codes.

Once done, check: Does your test code has good readability? Do you need to move around your code or your mouse in order to read your code?

Exercise 1.2

What if we want to add more logics:

Here are some sample inputs/outputs:7 = Wow14 = Wow21 = FizzWow35 = BuzzWow105 = FizzBuzzWow

Does your code has good maintainability? Can you add these logics without touching existing codes?

#Exercise 1.3

What if we want to change some wordings: