Eonirr

Untitled

May 24th, 2023
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. class Program
  2. {
  3. static void Main(string[] args)
  4. {
  5. Char ch;
  6. Console.WriteLine("Enter a character");
  7. ch =Convert.ToChar(Console.ReadLine());
  8. switch (ch)
  9. {
  10. case 'a':
  11. case 'e':
  12. case 'i':
  13. case 'o':
  14. case 'u':
  15. case 'A':
  16. case 'E':
  17. case 'I':
  18. case 'O':
  19. case 'U':
  20.  
  21. Console.WriteLine("Character is alphabet");
  22. break;
  23.  
  24. default:
  25. Console.WriteLine("Character is constant");
  26. break;
  27.  
  28. }
  29.  
  30. Console.ReadLine();
  31.  
  32. }
  33. }
Advertisement
Add Comment
Please, Sign In to add comment