fork download
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3.  
  4. int main() {
  5. // your code goes here
  6. int x, y;
  7. vector<int> t;
  8. for (x = 1; x < 5; x++) {
  9. for (y = 1; y <= 5; y++) {
  10. t.push_back(x+y+1+x*y);
  11. }
  12. }
  13. sort(t.begin(), t.end());
  14. for(x = 0; x < t.size(); x++) {
  15. cout << t[x] << endl;
  16. }
  17. return 0;
  18. }
Success #stdin #stdout 0s 4412KB
stdin
Standard input is empty
stdout
4
6
6
8
8
9
10
10
12
12
12
15
15
16
18
20
20
24
25
30