Wrote 1st and 2nd program for Chapter 3