Modified Main Method