Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- public class Program
- {
- public static void Main()
- {
- string day = Console.ReadLine();
- switch (day)
- {
- case "Monday": Console.WriteLine(1); break;
- case "Tuesday": Console.WriteLine(2); break;
- case "Wednesday": Console.WriteLine(3); break;
- case "Thursday": Console.WriteLine(4); break;
- case "Friday": Console.WriteLine(5); break;
- case "Saturday": Console.WriteLine(6); break;
- case "Sunday": Console.WriteLine(7); break;
- default: Console.WriteLine("invalid input"); break;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement