Assignment 4
Due (Online) Fri, Oct 6, 06, by 8:00 PM.
Write a C++ program to do the following
· It reads in a character and displays the alphabetical order of the character if the character is a lowercase letter or an uppercase letter and displays "Not a Letter" if the character is not a letter. For example, if the input is f, then your program should display 6. If the input is F, then your program should display 6. If the input is $, then your program should display "Not a Letter".
· Then it asks the user whether he/she wants to continue. If the user enters y or Y, then it repeats the whole process. If the user enters something else, it stops executing.
Useful Stuff:
§ Function tolower(char ch) returns the lowercase version of the character ch if it.s an uppercase letter and returns the character as it.s if it is not an uppercase letter.
§ Function toupper(char ch) returns the uppercase version of the character ch if it.s a lowercase letter and returns the character as it.s if it is not a lowercase letter.
§ Function isalpha(char ch) returns true if the character ch is a letter and returns false otherwise.
§ Function isdigit(char ch) returns true if the character ch is a digit (0..9) and returns false otherwise.
§ Function islower(char ch) returns true if the character ch is a lowercase letter and returns false otherwise.
§ Function isupper(char ch) returns true if the character ch is an uppercase letter and returns false otherwise.