Explain Enum in Swift?

An enum in swift is used to defines a common type for a group of related values. It enables you to work with those values in a type-safe way within your code.

Basically, it is a type that contains a group of various related values under the same umbrella.

Comments

Popular posts from this blog

In Swift, Optionals and Optional Binding are key concepts for handling values ?

What is benifit of using higher order functions?

Swift Optionals and force unwrapping?