51Nod 1384 全排列(next-permutation)
来源:互联网 发布:慕课平台有哪些 知乎 编辑:程序博客网 时间:2024/05/17 11:59
题目链接
#include<iostream>#include<algorithm>#include<cstdio>#include<cstring>#include<cmath>#include<vector>#include<queue>using namespace std;int main(){char s[11];cin>>s;int a[20],len=strlen(s);for(int i=0;i<len;i++) a[i]=s[len-i-1]-'0';sort(a,a+len); do{for(int i=0;i<len;i++) cout<<a[i];cout<<endl;}while(next_permutation(a,a+len));return 0;}
阅读全文
1 0
- 51Nod 1384 全排列(next-permutation)
- Next Permutation下一个全排列序列
- 全排列,next-permutation 简单实现
- 【poj】2718全排列next—permutation
- 1384全排列【51NOD】
- 51NOD 1384 全排列
- 51nod 1384 全排列
- 51Nod--1384全排列
- 51NOD 1384 全排列
- 51nod 1384 全排列
- 51nod 1384全排列
- 51nod 1384 全排列
- 51nod 1384 全排列
- 51Nod 1384 全排列
- 51nod 1384 全排列
- 51nod 1384 全排列
- 【51Nod】1384 全排列
- 51nod 1384 全排列
- Head First设计模式之迭代器模式
- No valid bower.json was found in any branch ...
- Python字符串格式化--format()方法
- 235. Lowest Common Ancestor of a Binary Search Tree
- 数据结构C语言链栈
- 51Nod 1384 全排列(next-permutation)
- P1308 统计单词数
- java中String数组和List的互相转化
- 下载一个电影,普通下载方式和utorrent方式,速度为什么差这么多?原理是什么?
- kdelibs的大致介绍
- 20170910WindowsPrj06_注册表操作
- 51Nod 2006 飞行员配对(二分图最大匹配) 匈牙利算法
- 爬虫入门四(多线程爬虫)
- Java版某东机试题