Skip to content
Sharp

API Evolution · interview question

Which class would you use to represent a date without a time-zone in the java.time package?

Multiple choiceEasychapter-12-curatedpremiumapi-evolutionmodern-date-and-time
Choose one answer
Answer and explanation

Correct answer

C. LocalDate

Why

The LocalDate class is used to represent a date without any time-zone information. It is useful for storing dates like birthdays or anniversaries.

Test yourself on API Evolution

A free test with instant, explained results. No account needed.

Start free test
All API Evolution questions →