Advertisement
IISergeyII

Untitled

May 17th, 2018
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.47 KB | None | 0 0
  1. #include <iostream>
  2. #include <cmath>
  3. #include <algorithm>
  4. #include <math.h>
  5. #include <vector>
  6. #include <fstream>
  7.  
  8. using namespace std;
  9.  
  10. int main()
  11. {
  12.     const int N = 3;
  13.     int coins[N] = {1, 2, 3};
  14.     for (int i = 0; i < N; i++) {
  15.         for (int j = i+1; j < N; j++) {
  16.             for (int l = j+1; l < N; l++) {
  17.                 cout << coins[i] << coins[j] << coins[l];
  18.                 cout << endl;
  19.             }
  20.         }
  21.     }
  22.  
  23.  
  24.  
  25.     return 0;
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement