In Java, the word true is ___________________?
Correct answer: A. A Boolean literal
- A. A Boolean literal
- B. A Java keyword
- C. Same as value 0
- D. Same as value 1
Explanation
`true` is a Boolean literal in Java, alongside `false`; it is not a keyword and Java does not treat it as numeric 0 or 1.
Report an error
The more specific you are, the faster it gets fixed. A source beats an opinion.
Prefer email? [email protected]
Practise Software Design and Architecture
493 free Software Design and Architecture MCQs from Software Engineering, each with the correct answer and an explanation. Unlimited attempts, no account needed.
Discussion
Stuck on an option, or know a faster way to get there? Ask or explain it here.
No comments yet. Be the first to explain this one.
Exams that ask Software Engineering questions like this
Software Engineering is on this paper prepared for on TestUstad, and all of them draw the same bank, so this question is worth knowing for it.
More Software Design and Architecture questions
In java, gc() method is available in which package ?
Which method can't be overidden ?
In Java byte, short, int and long all of these are ____________?
A method within a class is only accessible by classes that are defined within the same package as the class of the method. Which one of the following is used to enforce such restriction ?
javah stands for ?
Which of the following command is used to compile the Java program ?