Computer Applications
What are the points to be taken care while naming a class in a Java program?
Java Intro
101 Likes
Answer
A class name should be a valid Java identifier i.e. it should follow the below three rules:
- Name of the class should be a sequence of alphabets, digits, underscore and dollar sign characters only.
- It should not start with a digit.
- It should not be a keyword or a boolean or null literal.
Answered By
66 Likes