Assignment 1.1 - Fix the bugs

See here.