fork download
  1. // To understand what is happening in this file, please go to the end of the file.
  2.  
  3. #include "bits/stdc++.h"
  4.  
  5. #define int long long
  6. #define vi vector< int >
  7. #define fastIO() ios::sync_with_stdio(0),cin.tie(0),cout.tie(0);
  8. #define all(x) x.begin(),x.end()
  9. #define endl '\n'
  10.  
  11. using namespace std;
  12.  
  13. /*
  14.  
  15.  
  16.   ▄████ ██▓ ██▓▄▄▄█████▓ ▄████▄ ██░ ██
  17.  ██▒ ▀█▒▓██▒ ▓██▒▓ ██▒ ▓▒▒██▀ ▀█ ▓██░ ██▒
  18. ▒██░▄▄▄░▒██░ ▒██▒▒ ▓██░ ▒░▒▓█ ▄ ▒██▀▀██░
  19. ░▓█ ██▓▒██░ ░██░░ ▓██▓ ░ ▒▓▓▄ ▄██▒░▓█ ░██
  20. ░▒▓███▀▒░██████▒░██░ ▒██▒ ░ ▒ ▓███▀ ░░▓█▒░██▓
  21.  ░▒ ▒ ░ ▒░▓ ░░▓ ▒ ░░ ░ ░▒ ▒ ░ ▒ ░░▒░▒
  22.   ░ ░ ░ ░ ▒ ░ ▒ ░ ░ ░ ▒ ▒ ░▒░ ░
  23. ░ ░ ░ ░ ░ ▒ ░ ░ ░ ░ ░░ ░
  24.   ░ ░ ░ ░ ░ ░ ░ ░ ░
  25.  
  26. */
  27.  
  28. template<typename typC> istream &operator>>(istream &cin,vector<typC> &a) { for (auto &x:a) cin>>x; return cin; }
  29. template<typename typC> ostream &operator<<(ostream &cout,const vector<typC> &a) { int n=a.size(); if (!n) return cout; cout<<a[0]; for (int i=1; i<n; i++) cout<<' '<<a[i]; return cout; }
  30.  
  31.  
  32.  
  33. void itIsADream(){
  34. int n; cin >> n;
  35. cout << -(n-1) << ' ' << n << endl;
  36. }
  37.  
  38. int32_t main()
  39. {
  40. fastIO();
  41. // freopen("input.txt", "r", stdin);
  42. // freopen("output.txt", "w", stdout);
  43. int t = 1;
  44. cin >> t;
  45. while (t--)
  46. {
  47. itIsADream();
  48. }
  49. return 0;
  50. }
  51.  
  52. // to understand what is happening in this file, please go to the starting of the file.
Success #stdin #stdout 0.01s 5320KB
stdin
Standard input is empty
stdout
1 0