Question: what is difference between static block and main method?
Answer: jvm call public static void main() method to start application. as well as static block also executed after classes loaded. without main() the program gives main method not found exception but you can avoid this error by adding System.