PKU 1731 Orders
http://poj.org/problem?id=1731
与えられた文字からなる順列を全て生成する。
next_permutation
main(){ string in; cin>>in; sort(ALL(in)); do{ cout<<in<<endl; }while(next_permutation(ALL(in))); }
http://poj.org/problem?id=1731
与えられた文字からなる順列を全て生成する。
next_permutation
main(){ string in; cin>>in; sort(ALL(in)); do{ cout<<in<<endl; }while(next_permutation(ALL(in))); }