Guest User

Untitled

a guest
Dec 12th, 2017
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. #include <algorithm>
  2. #include <iostream>
  3. #include <fstream>
  4. #include <string>
  5. #include <iterator>
  6.  
  7. using namespace std;
  8.  
  9. int main()
  10. {
  11. string inputword;
  12. string words;
  13. cin >> inputword;
  14. ifstream fin("Words.txt");
  15. fin >> words;
  16. istream_iterator<string> eof;
  17. bool found = find(istream_iterator<string>(fin), eof, inputword) != eof;
  18. cout << found;
  19. system("pause");
  20. }
Add Comment
Please, Sign In to add comment