68 229
Assignments Done
99%
Successfully Done
In November 2018

Answer to Question #46357 in C# for Dipini Nayak

Question #46357
write a program to check whether given alphabet is vowel or not using switch case
Expert's answer
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace quesVowel
{
    class Program
    {
        static void Main(string[] args)
        {
            string character;
            Console.WriteLine("Enter the character");
            character = Console.ReadLine();
            switch (character)
            {
                case "A":
                case "a":
                case "E":
                case "e":
                case "I":
                case "i":
                case "O":
                case "o":
                case "U":
                case "u":
                    Console.WriteLine(character + " is a vowel");
                    break;
                default:
                    Console.WriteLine(character + " is not a vowel");
                    break;
            }
          
            Console.ReadLine();
        }
    }
}


Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions