Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace _13.Vowel_or_Digit
- {
- class Program
- {
- static void Main(string[] args)
- {
- char a = Convert.ToChar(Console.ReadLine());
- char[] vowelList = { 'a', 'e', 'i', 'o', 'u' };
- foreach (char vowel in vowelList)
- {
- if (vowel == a)
- {
- Console.WriteLine("vowel");
- return;
- }
- }
- if (char.IsNumber(a))
- {
- Console.WriteLine("digit");
- }
- else
- {
- Console.WriteLine("other");
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement