Last updated
Was this helpful?
Was this helpful?
public enum DaysOfWeek
{
Sunday = 0,
Monday = 1,
Tuesday = 2,
Wednesday = 3,
Thursday = 4,
Friday = 5,
Saturday = 6,
}int day = (int)DaysOfWeek.Sunday;DaysOfWeek today = (DaysOfWeek)3;var today = Enum.Parse<DayOfWeek>("Sunday");