Added code for assignments 2 (complete) and 3 (partial implementation).