daily pastebin goal
55%
SHARE
TWEET

Untitled

a guest Jun 14th, 2018 45 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <conio.h>
  2. #include <iostream>
  3. #include <fstream>
  4. //#include <sys/select.h>
  5. #include <unistd.h>
  6. //#include <sys.types.h>
  7. //#include <termios.h>
  8. #include <unistd.h>
  9. #include <cstdlib>
  10.  
  11. using namespace std;
  12.  
  13. int main()
  14. {
  15.     unsigned char znak;
  16.  
  17.     int i;
  18.     cout << "ESC " << endl;
  19.     do
  20.     {
  21.  
  22.         znak=getchar();
  23.         ofstream plik ("zapis.txt");
  24.         plik.open("zapis.txt",ios::out | ios::app);
  25.         cout << "Znak: " << znak << "' kod: " << static_cast < int > ( znak ) << endl;
  26.         cout << endl;
  27.         for( i = 1; i <= 100; i++ )
  28.         {
  29.            plik << znak;
  30.         }
  31.  
  32.         plik.close();
  33.     } while(znak != 27);
  34.     return 0;
  35. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top