题解 | 全排列

全排列

https://www.nowcoder.com/practice/1d1fe38275da44b5848add89f9e223b1

print('\n'.join(' '.join(map(str, p)) for p in permutations([i for i in range(1, II() + 1)])))

全部评论

相关推荐

评论
2
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务