fork download
  1. #include <iostream>
  2. #include <conio.h>
  3. using namespace std;
  4.  
  5. int main() {
  6.  
  7. char key = ' ';
  8. while (key != 'q'){
  9. cout << "Enter a key: ";
  10. key = _getch();
  11. cout << "You entered: " << key << endl;
  12. }
  13.  
  14. return 0;
  15. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
hghskjgh s d sd f s 234q
compilation info
prog.cpp:2:19: fatal error: conio.h: No such file or directory
compilation terminated.
stdout
Standard output is empty