Solving Problem 9. Also, fixing up a lil bug in the solution.c.template file.