What are literals in Java? - ICSE Java Expert

Breaking

ICSE Java Expert

Learn Java for school

Unordered List

WELCOME

Monday, August 06, 2018

What are literals in Java?

Literals are constants (values) assigned to a variable (identifier).

int age = 12;
In this example 12 is literal i.e. it is a value that has been assigned to the variable age.




No comments:

Post a Comment