Answer to the question number 1:
In Java, static keywords are mainly used for memory management. We can use static keywords with variables, methods, blocks and home classes.
If the static keyword is applied to a class, all the members of the class must be static. Classes, interfaces, and static classes may have static constructors.
Answer to the question number 2:
Naming an appropriate method increases reading and understanding of the purpose of the method. Multiply
(int x, int y) Here you will immediately understand that this method will multiply the double digit values.
This increases the reusability of the code and thus reduces the size of the code.
The complex problem can be modulated with the help of methods.
If the code is written without method, it will be very large in size and thus it will be difficult to test, correct and maintain the code.