create_lists.cpp
void remove_vowelless() {
    word_occ ptr;

    // catalogue starting data for analysis purposes
    std::cout << "Removing voweless." << '\n';
    std::cout << "Starting list size is: " << words_vector.size() << '\n';
    int start = words_vector.size();

    // go through each word in the vector
    for (std::vector<word_occ>::iterator it = words_vector.begin(); it != words_vector.end(); ++it) {
        ptr = *it;

        // convert strings into c-strings to check individual characters within them
        const char* wordc = ptr.word.c_str();
        int vowel_check = 0;

        // check for the presence of a vowel
        // if found, stop searching and move on
        for (int i = 0; i < strlen(wordc); i++) {
            if (wordc[i] == 'a' || wordc[i] == 'e' || wordc[i] == 'i' || wordc[i] == 'o' || wordc[i] == 'u' || wordc[i] == 'y') {
                vowel_check = 1;
                break;
            }
        }

        // if no vowels were found, remove that word from the vector, and continue to the next word
        if (vowel_check == 0) {
            words_vector.erase(it);
        } 
    }


    // output how many words remain and the amount of words removed for analysis purposes
    std::cout << "Size after removing vowelless is: " << words_vector.size() << '\n';
    int diff = start - words_vector.size();
    std::cout << "---Removed " << diff << " entries" << '\n' << "==========================================================" << '\n' << '\n';
}
/*
no real english words lack vowels entirely, this function will remove all instances of words in the list that contain zero vowels.
this is designed to remove things like acronyms from the dataset
*/
no real english words lack vowels entirely, this function will remove all instances of words in the list that contain zero vowels.
this is designed to remove things like acronyms from the dataset
no real english words lack vowels entirely this function will remove all instances of words in the list that contain zero vowels . this is designed to remove things like acronyms from the dataset
void remove_vowelless() {
    word_occ ptr;
    std::cout << "Removing voweless." << '\n';
    std::cout << "Starting list size is: " << words_vector.size() << '\n';
    int start = words_vector.size();
    for (std::vector<word_occ>::iterator it = words_vector.begin(); it != words_vector.end(); ++it) {
        ptr = *it;
        const char* wordc = ptr.word.c_str();
        int vowel_check = 0;
        for (int i = 0; i < strlen(wordc); i++) {
            if (wordc[i] == 'a' || wordc[i] == 'e' || wordc[i] == 'i' || wordc[i] == 'o' || wordc[i] == 'u' || wordc[i] == 'y') {
                vowel_check = 1;
                break;
            }
        }
        if (vowel_check == 0) {
            words_vector.erase(it);
        } 
    }
    std::cout << "Size after removing vowelless is: " << words_vector.size() << '\n';
    int diff = start - words_vector.size();
    std::cout << "---Removed " << diff << " entries" << '\n' << "==========================================================" << '\n' << '\n';
}
void remove_vowelless ( ) { word_occ ptr ; std :: cout << " " << ' \n ' ; std :: cout << " " << words_vector . size ( ) << ' \n ' ; int start = words_vector . size ( ) ; for ( std :: vector < word_occ > :: iterator it = words_vector . begin ( ) ; it != words_vector . end ( ) ; ++ it ) { ptr = * it ; const char * wordc = ptr . word . c_str ( ) ; int vowel_check = 0 ; for ( int i = 0 ; i < strlen ( wordc ) ; i ++ ) { if ( wordc [ i ] == ' ' || wordc [ i ] == ' ' || wordc [ i ] == ' ' || wordc [ i ] == ' ' || wordc [ i ] == ' ' || wordc [ i ] == ' ' ) { vowel_check = 1 ; break ; } } if ( vowel_check == 0 ) { words_vector . erase ( it ) ; } } std :: cout << " " << words_vector . size ( ) << ' \n ' ; int diff = start - words_vector . size ( ) ; std :: cout << " " << diff << " " << ' \n ' << " " << ' \n ' << ' \n ' ; }
no real english words lack vowels entirely, this function will remove all instances of words in the list that contain zero vowels.
no real english words lack vowels entirely this function will remove all instances of words in the list that contain zero vowels .
// catalogue starting data for analysis purposes
 // go through each word in the vector
 // convert strings into c-strings to check individual characters within them
 // check for the presence of a vowel
 // if found, stop searching and move on
 // if no vowels were found, remove that word from the vector, and continue to the next word
 // output how many words remain and the amount of words removed for analysis purposes
