Update homework.py

q3 - http://www.codeskulptor.org/#user34_NsI6bIrSa6_16.py