Question
Which statement about Optional is the strongest interview answer?
- Optional is mostly a naming style choice and has little effect on runtime or design.
- Optional exists mainly to reduce the number of Java files in a project.
- Optional models potentially missing return values without using raw null as the main signal.
- Optional matters only for frontend frameworks, not for core Java applications.
Hint
Start with the core rule behind Optional.
Answer and rationale
Correct answer: C. Optional models potentially missing return values without using raw null as the main signal.
Optional models potentially missing return values without using raw null as the main signal. This is the base concept interviewers commonly test first.
Track: Java