(hopefully) finished debugging program3 for cs520, everything seems to be working, but I'll try and do some more testing