fork(1) download
  1. #define R(p) rand()%('9'-(p)+1)+(p)
  2. #define P(p) putc((p),stdout)
  3. #define PP(p) P(R(p))
  4.  
  5. #include <iostream>
  6. #include <cstdlib>
  7.  
  8. #include <cstdio>
  9.  
  10. using namespace std;
  11.  
  12.  
  13. void gen(int x)
  14. {
  15. if (x) PP('1'); else PP('0');
  16. for(;x;x--) PP('0');
  17. }
  18.  
  19. int main()
  20. {
  21. int a, d, n;
  22. cin >> a; srand(a);
  23. cin >> d; cin >> n; cout << n << endl;
  24. for(;n;n--)
  25. {
  26. gen(rand()%d); P(' ');
  27. gen(rand()%d); P('\n');
  28. }
  29. return 0;
  30. }
  31.  
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cs(2,0): error CS1025: Single-line comment or end-of-line expected
prog.cs(3,0): error CS1025: Single-line comment or end-of-line expected
prog.cs(4,0): error CS1025: Single-line comment or end-of-line expected
prog.cs(6,0): error CS1024: Wrong preprocessor directive
prog.cs(7,0): error CS1024: Wrong preprocessor directive
prog.cs(9,0): error CS1024: Wrong preprocessor directive
prog.cs(10,6): error CS1525: Unexpected symbol `namespace', expecting `identifier' or `static'
prog.cs(10,19): error CS1525: Unexpected symbol `;', expecting `identifier' or `static'
prog.cs(15,1): error CS1525: Unexpected symbol `if', expecting `identifier' or `static'
prog.cs(17,1): error CS1514: Unexpected symbol `}', expecting `.' or `{'
Compilation failed: 10 error(s), 0 warnings
stdout
Standard output is empty