What is ENUM?

Answer Posted / pijush

The enum keyword is used to declare an enumeration, a
distinct type consisting of a set of named constants called
the enumerator list. Every enumeration type has an
underlying type, which can be any integral type except
char. The default underlying type of the enumeration
elements is int. By default, the first enumerator has the
value 0, and the value of each successive enumerator is
increased by 1. For example:

Is This Answer Correct ?    23 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is array reference type in c#?

490


Do events have return type c#?

510


What is the difference between dispose() and finalize() methods in c#?

511


What is xslt in c#?

474


What is difference between tostring() vs convert.tostring() vs (string) cast

552






Which is faster array or arraylist in c#?

483


Define method overloading in c#?

592


How does foreach loop work in c#?

485


Which is better javascript or c#?

507


What are different types of Delegates in C#?

567


Explain About DTS package

578


In languages without exception-handling facilities, we could send an error-handling procedure as a parameter to each procedure that can detect errors that must be handled. What disadvantages are there to this method?

602


Why do we overload constructors?

497


List the two important objects of ado.net and also list the namespaces that are commonly used in ado.net to aid in connection to a database.

522


What are custom exceptions? Why do we need them?

527