assignment 5, part 3, source code and graphics