Which of the following is a Literal Representation?
A. 100
B. ‘100’
C. Sample
D. None of the mentioned
Answer:A
Which of the following is a Literal Representation?
A. 100 B. ‘100’ C. Sample D. None of the mentioned
Explanation: A constant value in Java is created by using a ‘Literal Representation’ of it. Integer Literals are not enclosed in quotes where as String Literals are enclosed in quotes.