solution for hw 2 main 1452747