An enum provides a set of related values:
enum Direction {
case up
case down
case left
case right
}
enum Direction { case up, down, left, right }
Enum values can be used by their fully-qualified name, but you can omit the type name when it can be inferred:
let dir = Dire...