D

Dhruva Jagannath • 660 Points
Invincible

Q. Which enum constant syntax allows defining constant-specific behavior?

  • (A) NORMAL
  • (B) SPECIAL()
  • (C) SPECIAL { @Override method }
  • (D) static SPECIAL
  • Correct Answer - Option(C)
  • Views: 12
  • Filed under category Java
  • Hashtags: Java Enums

Explanation by: Dhruva Jagannath
You can override methods per constant using constant-specific class body: `CONSTANT { ... }`

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.