Skip to content

Latest commit

 

History

History
14 lines (11 loc) · 276 Bytes

File metadata and controls

14 lines (11 loc) · 276 Bytes

Variants

We call the different possibilities that an enum represents its "variants."

So in the following code we would say that the TirePressure enum has three variants: LOW, NORMAL, and HIGH.

enum TirePressure {
    LOW,
    NORMAL,
    HIGH
}