Source code for homework