Quiz: Enum Classes

Test your understanding of the concepts discussed in this chapter.

1

What is the purpose of defining a primary constructor for an enum class?

A)

To provide methods for enum values

B)

To allow changes to the state of enum values

C)

To make the enum class mutable

D)

To specify data for each enum value

Question 1 of 40 attempted

Get hands-on with 1200+ tech skills courses.