achieve the main method