finished hw3 .py files