Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //#pragma GCC optimize("Ofast")
- //#pragma GCC target("avx")
- #include <bits/stdc++.h>
- #include <ext/pb_ds/assoc_container.hpp>
- #include <ext/pb_ds/tree_policy.hpp>
- using namespace __gnu_pbds;
- using namespace std;
- #define fi first
- #define se second
- #define pb push_back
- #define sz(x) ((int)x.size ())
- #define all(x) (x).begin(), (x).end()
- #define re return
- #define mp make_pair
- #define sqrt(x) sqrt (abs(x))
- #define y0 y3451
- #define y1 y4562
- #define j0 j25624
- #define j1 j45624
- #define makeunique(x) sort(all(x)), (x).resize (unique(all(x)) - (x).begin())
- typedef pair <int, int> ii;
- typedef long long ll;
- typedef unsigned long long ull;
- typedef double D;
- typedef long double ld;
- typedef unsigned int uint;
- typedef vector <string> vs;
- typedef vector <int> vi;
- typedef vector <ii> vii;
- typedef vector <vi> vvi;
- template <class T> using _tree = tree<T, null_type, less<T>, rb_tree_tag,tree_order_statistics_node_update>;
- template <class T> T abs (T x) { re x > 0 ? x : -x; }
- template <class T> T sqr (T x) { re x * x; }
- template <class T> T gcd (T a, T b) { re a ? gcd (b % a, a) : b; }
- template <class T> int sgn (T x) { re x > 0 ? 1 : (x < 0 ? -1 : 0); }
- #define filename ""
- const int N = 2e5 + 20;
- const int inf = 1e9 + 20;
- int n, m;
- int main()
- {
- // freopen("out.txt", "w", stdout);
- srand(time(0));
- n = m = 3000;
- int k = 40;
- cout << n << " " << m << endl << k << endl;
- for (int i = 0; i < k; i++) {
- int x, y;
- x = rand() % n;
- y = rand() % m;
- cout << x + 1 << " " << y + 1 << "\n";
- }
- int t = 1;
- for (int i = 0; i + 1 < 500; i++) {
- t = t + 1 + rand() % 300;
- cout << t << " ";
- int x, y;
- x = rand() % n;
- y = rand() % m;
- cout << x + 1 << " " << y + 1 << " ";
- x = rand() % n;
- y = rand() % m;
- cout << x + 1 << " " << y + 1 << "\n";
- }
- for(int i = 0; i < 5; i++)
- cout << -1 << " ";
- cout << "\n";
- re 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement