Guest User

как бы эта штука выглядела в C?

a guest
May 9th, 2020
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.30 KB | None | 0 0
  1. #include <algorithm>
  2. #include <iostream>
  3. #include <vector>
  4.  
  5. using namespace std;
  6.  
  7. int main() {
  8.   int n;
  9.   cin >> n;
  10.  
  11.   vector<char> v{a,b,c,d,e,f,g,h,i,j};
  12.  
  13.   do {
  14.     for (auto i : v) {
  15.       cout << i << " ";
  16.     }
  17.     cout << endl;
  18.  
  19.   } while (next_permutation(v.begin(), v.end())w);
  20. }
Add Comment
Please, Sign In to add comment