题解列表

筛选

二级C语言-计算素数和,差点被坑了

摘要:解题思路:输入,判断是否大于1,写函数,输出注意事项:1既不是质数也不是合数;参考代码:#include<iostream> #include <vector> #include <stdbool……

考察经典Switch语句的用法

摘要:解题思路:考察经典Switch语句的用法注意事项:注意switch语句是先找到符合项才继续执行的,时间久了,有点忘了参考代码:#include<iostream> using namespace s……

1130数数字(for循环遍历)

摘要:解题思路:注意事项:参考代码:#include<iostream>#include<cstring>using namespace std;int main(){ char s[100]; cin >……

1129排序问题(2)(sort排序)

摘要:解题思路:注意事项:参考代码:#include<iostream>#include<algorithm>using namespace std;bool compare(int p1, int p2)……

1128排序问题(1)(sort排序)

摘要:解题思路:注意事项:参考代码:#include<iostream>#include<algorithm>using namespace std;bool compare(int p1, int p2)……