What is enum in C#?

Asked 19-Dec-2017
Viewed 609 times

2 Answers


1

In programming Language, an enumerated type (also called enumeration, enum, or factor in the R programming language, and a categorical variable in statistics) is a data type consisting of a set of named values called elements, members, enumeral, or enumerators of the type.

2

What is enum in C#?

The enum keyword is used to create numeric constants in .NET framework. Its a value type with a set of related named constants often referred to as an enumerator list. It's a primitive data type, which is user-defined and this keyword is used to declare an enumeration. enum all members are of an enum type. It's should be a numeric value for each enum type. By default enumeration underlying type is int.