Main Method auto generation in java Eclipse example

Main Method auto generation in java Eclipse example

As we know main method is first method java begins its execution. That main method we can generate using two ways in eclipse
Way 1:

While creating the class, we can enable the “public static main method(String[] args) checkbox”,

AutoGenCreate

Way 2:

If we have created the class without enabling the checkbox, then no need to delete and create it again. We can simply create simply typing main with ctrl+shift.

AutoGenCtrlShift

Recommended Books:

528 total views, 2 views today

Leave a Reply

Your email address will not be published. Required fields are marked *