How do I find the next permutation of a list

后端 未结 0 1904
情书的邮戳
情书的邮戳 2020-12-18 06:47

If I am given a list of numbers from 1 to N, How do I find the next permutation of a given list?

For example:

lst = [2, 1, 4, 3]

the n

相关标签:
回答
  • 消灭零回复
提交回复
热议问题