Curioustab
Aptitude
General Knowledge
Verbal Reasoning
Computer Science
Interview
Aptitude
General Knowledge
Verbal Reasoning
Computer Science
Interview
Home
»
C# Programming
»
Enumerations
Which of the following statements is correct about the C#.NET code snippet given below? int a = 10; int b = 20; int c = 30; enum color: byte { red = a, green = b, blue = c }
Variables cannot be assigned to enum elements.
Variables can be assigned to any one of the enum elements.
Variables can be assigned only to the first enum element.
Values assigned to enum elements must always be successive values.
Values assigned to enum elements must always begin with 0.
Show Answer
Correct Answer:
Variables cannot be assigned to enum elements.
← Previous
Next →
Discussion & Comments
No comments yet. Be the first to comment!
Name:
Comment:
Post Comment