摘要: 这里写一些零碎小知识,会更新,也欢迎同道中人评论分享自己的解题小技巧~ 1. 万能头文件 #include<bits/stdc++.h> 2. 字符串输入 cin >> s; //以空格为分隔符 getline(cin, s); //以回车为分隔符,但注意使用前若有scanf()则必须使用getch 阅读全文
posted @ 2019-07-22 23:03 落月成孤倚♪ 阅读(120) 评论(0) 推荐(0) 编辑
摘要: 按顺序输出n位数的全排列,n位数为1-n。如n=3,则输出123,132,213,231,312,321 参考文章:https://www.cnblogs.com/aiguona/p/7304945.html 1)next_permutation:求下一个排列组合 a.函数模板:next_permu 阅读全文
posted @ 2019-07-22 23:02 落月成孤倚♪ 阅读(503) 评论(0) 推荐(0) 编辑