Home work -CW10.6, ringbuffer component