Prepare Interview

Mock Exams

Make Homepage

Bookmark this page

Subscribe Email Address

Core%20Java%20Interview%20Questions%20and%20Answers

Question: What is literals in core java?
Answer:
Java Literals are syntactic representations of boolean, character, numeric, or string data. Literals provide a means of expressing specific values in your program. For example, in the following statement, an integer variable named count is declared and assigned an integer value. The literal 0 represents, naturally enough, the value zero.
int count = 0;
Boolean literals: true, false
Some numeric literals: 1233, 554.334, -78
Is it helpful? Yes No

Most helpful rated by users:

©2024 WithoutBook