Q:

Enumeration concept using C# Language

0

This Program is used to demonstrate the enumeration concept.

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

using System;



class Program

{

enum Days{Sun,Mon,Tue,Wed,Thu,Fri,Sat};



public static void Main()

{

int wstart =(int)Days.Mon;

int wend =(int)Days.Fri;



Console.WriteLine("\nMonday: {0}",wstart);

Console.WriteLine("\nFriday: {0}",wend);

}

}

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now