I dont know why my return proto type is having a error. Im sure is something really simple, but iv'e been working on it for 45 min. and still cant find the error.
#include <iostream>
using namespace std;
return bool isVowel(char ch)
int main()
{
char ch;
cout << "Enter a character from the alphbet:" << endl;
cin >> ch;
cout << "Is " << ch << " a vowel?" << isVowel << endl;
}
bool isVowel(char ch)
{
switch (ch)
case 'A':
case 'a':
case 'E':
case 'e':
case 'i':
case 'I':
case 'o':
case 'O':
case 'U':
case 'u':
return true;
default:
return false;
}
That's not how you write a function prototype - you're also missing a semi-colon.
bool isVowel(char ch);
This is what your function prototype should look like.
You should also add some break statements to your switch in the isVowel function.