Enumerated Type

What Does Enumerated Type Mean?

Enumerated type is a user-defined data type used in computer programming to map a set of names to numeric values. Enumerated data type variables can only have values that are previously declared. In other words, they work with a finite list of values.

Advertisements

Enumerated data types help make the code more self-documenting and prevent programmers from writing illogical code on values of enumerators. Enumerated data also hides unnecessary details from programmers.

Techopedia Explains Enumerated Type

Enumerator names usually behave as constants in programming languages, although they are identifiers in most ways. A variable assigned as enumerated type can have any of the enumerators as value.

In certain languages, enumerator data types many be built into the language. Many programming languages permit users to define new enumerated types and certain programming languages also define the ordering that needs to be followed for the members associated with enumerated data types. The enumerators are unique, but certain programming languages do permit the enumerator to be listed twice in the declaration of the type.

Advertisements

Related Terms

Latest Data Management Terms

Related Reading

Margaret Rouse

Margaret Rouse is an award-winning technical writer and teacher known for her ability to explain complex technical subjects to a non-technical, business audience. Over the past twenty years her explanations have appeared on TechTarget websites and she's been cited as an authority in articles by the New York Times, Time Magazine, USA Today, ZDNet, PC Magazine and Discovery Magazine.Margaret's idea of a fun day is helping IT and business professionals learn to speak each other’s highly specialized languages. If you have a suggestion for a new definition or how to improve a technical explanation, please email Margaret or contact her…