working on main program