文章

210

粉丝

0

获赞

894

访问

30.9k

头像
全排列 题解:
P1185 中国矿业大学/北京大学机考题
发布于2026年3月18日 19:14
阅读数 27

#include<bits/stdc++.h>
using namespace std;
int main(){
    string str;
	cin >> str;
	do{ 
		cout << str << endl;
	}while(next_permutation(str.begin(),str.end()));
    return 0;
}

 

登录查看完整内容


登录后发布评论

暂无评论,来抢沙发