• Home
  • Recent Q&A
  • Java
  • Cloud
  • JavaScript
  • Python
  • SQL
  • PHP
  • HTML
  • C++
  • Data Science
  • DBMS
  • Devops
  • Hadoop
  • Machine Learning
in C Sharp by
Q:
What is enum in C#?

1 Answer

0 votes
by
enum keyword is used for declaring an enumeration, which consists of named constants and it is called as enumerator lists. Enums are value types in C# and these can’t be inherited. Below is the sample code of using Enums

Eg: enum Fruits { Apple, Orange, Banana, WaterMelon};

Related questions

0 votes
asked May 6, 2020 in C Sharp by SakshiSharma
0 votes
asked May 6, 2020 in C Sharp by SakshiSharma
...