public class Main { static void myMethod() { System.out.println("My method"); } public static void main(String[] args) { myMethod(); } }