update main program