updated source to tutorial5, and changed it to the way I think it ought to run