/// G. Hagopian -- Experimenting with menus

#include <iostream>

/// The goal here is to look at ways to create a menu\
/// driven loop.

using namespace std;

/// prototypes
char menu();
void hat();
void crow();
void words();

int main() {
    char choice, repeat;

    do {
        choice = menu();
        switch(choice) {
        case '1' :
            hat();
            break;
        case '2' :
            crow();
            break;
        case '3' :
            words();
            break;
        default :
            break;
        }
        cout << "\nWould you like to do that agian? (Y:yes, N: no): ";
        cin >> repeat;
    } while(toupper(repeat)=='Y');


}

char menu(void) {
    char choice{'a'};
    cout << "\nWhat would you like to eat?\n";
    cout << "\n1. Your hat."
         << "\n2. Crow."
         << "\n3. Your words.\n";
    cin >> choice;
    return choice;
}

void hat() {
    string hat_type;
    cout << "\nWhat kind of hat would you like?\n";
    cin >> hat_type;
    cout << "\nHmmmm..." << hat_type << " hats are delicious.\n";
}
void crow() {

}
void words() {

}
