Which of the following is a valid java keyword?
Advertisements
प्रश्न
Which of the following is a valid java keyword?
पर्याय
If
BOOLEAN
static
Switch
MCQ
Advertisements
उत्तर
static
Explanation:
Keywords in Java are reserved terms with a defined meaning and purpose within the language. Keywords should always be written in lowercase. Analyzing the provided options:
If:Incorrect because Java keywords are case-sensitive; the correct keyword is if (lowercase).BOOLEAN:Incorrect because the Java keyword is boolean (lowercase).static:This is correct; static is a valid Java keyword for declaring static methods, variables, or blocks.Switch:Incorrect since the right keyword is switch (lowercase).
shaalaa.com
Tokens
या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?
