Need help with my senior level algorithms class. I have attached the homework below. Need to finish the whole thing before Monday.