Advertisement
newb_ie

Untitled

Dec 2nd, 2021
202
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. #include "bits/stdc++.h"
  2.  
  3. using namespace std;
  4.  
  5. #define filein freopen ("input.txt", "r", stdin)
  6. #define fileout freopen ("output.txt", "w", stdout)
  7.  
  8. int main () {
  9. ios::sync_with_stdio(false);
  10. cin.tie(nullptr);
  11. cout.tie(nullptr);
  12. fileout;
  13. int T = 10;
  14. cout << T << '\n';
  15. for (int test_case = 1; test_case <= T; ++test_case) {
  16. int N = rand() % 500 + 1;
  17. vector<int> a(N + 1);
  18. cout << N << '\n';
  19. for (int i = 1; i <= N; ++i) {
  20. a[i] = rand() % 1000 + 1;
  21. }
  22. for (int i = 1; i <= N; ++i) {
  23. cout << a[i] << ' ';
  24. }
  25. cout << '\n';
  26. }
  27. }
  28.  
  29.  
  30. //~ T => (1 - 10)
  31. //~ N => (1 - 500)
  32. //~ Ai => (1 - 1000)
  33.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement