fork download
  1. #include <iostream>
  2. #include <string>
  3. #include <cstdlib>
  4. #include <windows.h>
  5. #include <algorithm>
  6.  
  7. using namespace std;
  8.  
  9. int main() {
  10.  
  11. SetConsoleCP(1251);
  12. SetConsoleOutputCP(1251);
  13.  
  14. string s;
  15.  
  16. cout << "Введите последовательность символов (первый символ отличен от воскл. знака):" << endl;
  17. getline(cin, s);
  18.  
  19. cout << (min(s.find("он"), s.find("но")) < s.find('!') ? "Да, имеются." : "Нет, отсутствуют.") << endl;
  20.  
  21. system("pause");
  22. return 0;
  23. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp:4:21: fatal error: windows.h: No such file or directory
 #include <windows.h>
                     ^
compilation terminated.
stdout
Standard output is empty