Exercise 3.1

You are developing a class with several methods to handle data structure called Circular Buffer. First, try to understand how circular buffer works from Wikipedia. List out attributes and methods that your class should have. Give them proper names and define the input parameters and output parameters for your methods.

A 24-byte keyboard circular buffer.

A 24-byte keyboard circular buffer.

Exercise 3.2

Implement your class. Pick a method to start. Remember that you are doing TDD so you should begin by writing a test first. Complete each method one by one. Add attribute only when you need.

Observe which method did you pick first and how do you pick the next one. Find out what is the best way to do.

If possible, try to do this exercise with your friend(s). Every five minutes, change to another machine and continue coding from your friend(s). This is the best way to determine how good readability your code is :)