Advertisement
AkirusG

Untitled

Nov 23rd, 2014
165
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.15 KB | None | 0 0
  1. int main()
  2. { pasoc::bst++;
  3.     text input, output;
  4.     if(input == 0) input = random(); pasoc::files[input] = "input.txt";;
  5.     if(output == 0) output = random(); pasoc::files[output] = "output.txt";;
  6.     freopen(pasoc::files[input].c_str(), "r", __stdinp); pasoc::stdinname = pasoc::files[input];;
  7.     freopen(pasoc::files[output].c_str(), "w", __stdoutp); pasoc::stdoutname = pasoc::files[output];;
  8.  
  9.     longint i;
  10.     std::cin >> i;
  11.     pasoc::__add(0, 0); for(; i != 0 || pasoc::__st_pop_back(); pasoc::__increment())
  12.         std::cout << i-- << std::endl;
  13.  
  14.     pasoc::__add(&( i = 1 ),1); for(; *pasoc::__get() <= 100 || pasoc::__st_pop_back(); pasoc::__increment())
  15.     { pasoc::bst++;
  16.         longint j;
  17.         pasoc::__add(&( j = 100 ), 2); for(; *pasoc::__get() >= 1 || pasoc::__st_pop_back(); pasoc::__increment())
  18.             if( i == j or i*i == j )
  19.             { pasoc::bst++;
  20.                 std::cout << i*j << std::endl;
  21.             pasoc::bst--;}
  22.     pasoc::bst--;};
  23.  
  24.     fclose(pasoc::files[input] == pasoc::stdinname ? __stdinp : __stdoutp);;
  25.     fclose(pasoc::files[output] == pasoc::stdinname ? __stdinp : __stdoutp);;
  26. pasoc::bst--;}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement