what r the points to be taken care while naming a class in java program?
Answers
Answered by
36
It should start with capital letter.
It should have CamelCase.
It’s name should be meaningful (not Abc Xyz, foo, bar)
It should be nouns.
NOTE - if you don’t do above things it will compile, but you should follow these.
File name MUST match with the Class contains main method.
Answered by
40
Answer:
The points to be taken care of while naming a class, in a Java program are :
◾The class name must not be a Java reserved word.
◾As far as possible, the class name should be meaningful and relevant to the program.
Similar questions