Question: C++ searching a vector for commonly used words I need help with my code for a function which is supposed to look at a file
C++ searching a vector for commonly used words
I need help with my code for a function which is supposed to look at a file of the most used english words and search for those words in another .txt file. This is what I have so far:
bool isStopWord(string word, vector
for(int i = 0; i < _vecIgnoreWords.size() ; i++){
if(_vecIgnoreWords[i] == word)
return true;
else
return false;
}
return 0;
}
For example: "the dog went to the park" the should be identified as a Stop Word
We aren't allowed to use
Here is the .txt file of words:
the be to of and a in that have i it for not on with he as you do at this but his by from they we say her she or an will my one all would there their what so up out if about who get which go me
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
