Anonymous user
Talk:Next highest int from digits: Difference between revisions
Talk:Next highest int from digits (view source)
Revision as of 07:41, 24 February 2020
, 4 years ago→Next_permutation: sp.
(Using Permutations) |
m (→Next_permutation: sp.) |
||
(One intermediate revision by one other user not shown) | |||
Line 27:
==Next_permutation==
Someone on [https://www.reddit.com/r/coding/comments/f796q1/next_highest_int_from_digits/fi9uyx1?utm_source=share&utm_medium=web2x Reddit] r/coding posted a cryptic `std::next_permutation()`. Some searching shows that if it produces the next lexicographic permutation
==Ambiguities in task statement==
Line 48 ⟶ 47:
==Using Permutations==
Don't sort the permutations and then search for the specified condition. Map the permutations subtracting the original value. Reduce the
|