Skip to content

Instantly share code, notes, and snippets.

@zsol
Created July 28, 2011 18:53
Show Gist options
  • Save zsol/1112252 to your computer and use it in GitHub Desktop.
Save zsol/1112252 to your computer and use it in GitHub Desktop.
Solution for problem 24
int ints[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
for (int i = 1; i < 1000000; ++i) std::next_permutation(ints, ints+10);
for (int i = 0; i < 10; ++i) std::cout << ints[i];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment