Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <fstream>
- #include <vector>
- #include <algorithm>
- using namespace std;
- ofstream out("input.txt");
- int main()
- {
- int max;
- cin >> max;
- out << max << " " << max << endl;
- vector<int> N(max);
- for (int i=0; i<max; i++)
- {
- N[i] = i;
- out << i << " ";
- }
- out << endl;
- random_shuffle(N.begin(),N.end());
- for (int i=0; i<max; i++)
- out << N[i] << " ";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement