Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<bits/stdc++.h>
- #define endl '\n'
- using namespace std;
- #ifdef ONLINE_JUDGE
- #define eprintf(...) 42
- #else
- #define eprintf(...) {fprintf(stderr, __VA_ARGS__);fflush(stderr);}
- #endif
- clock_t startTime;
- double getCurrentTime()
- {
- return (double)(clock() - startTime) / CLOCKS_PER_SEC;
- }
- mt19937_64 gen(chrono::steady_clock::now().time_since_epoch().count());
- const int N = 100000;
- int solve()
- {
- uniform_int_distribution<int> rnd(1, 1e9);
- cout<<N<<endl;
- for(int i=0; i<N; i++)
- {
- cout<<rnd(gen)<<" ";
- }
- cout<<endl;
- return 0;
- }
- int main()
- {
- ios::sync_with_stdio(false);
- cin.tie(0);
- int t=1;
- //cin>>t;
- startTime = clock();
- while(t--)
- {
- startTime = clock();
- solve();
- }
- eprintf("time = %.5lf\n", getCurrentTime());
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment