Josh: Almost working solution for euler 96