摘要: 题目 日期类的题目基本都要找一个起点,提前预处理 代码 1 #include<iostream> 2 #include<algorithm> 3 using namespace std; 4 //判断是否是闰年或平年 5 int ISYEAP(int x){ 6 if((x %100 != 0 && 阅读全文
posted @ 2021-03-01 21:42 Uitachi 阅读(67) 评论(0) 推荐(0)
摘要: 题目 代码 1 #include<iostream> 2 #include<cstring> 3 #include<algorithm> 4 using namespace std; 5 int main(){ 6 char str[201]; 7 cin>>str; 8 int n = strle 阅读全文
posted @ 2021-03-01 20:17 Uitachi 阅读(55) 评论(0) 推荐(0)
摘要: 题目 代码 1 #include<iostream> 2 #include<algorithm> 3 #include<string.h> 4 using namespace std; 5 typedef struct stu{ 6 char cno[10]; 7 char name[10]; 8 阅读全文
posted @ 2021-03-01 18:37 Uitachi 阅读(84) 评论(0) 推荐(0)
摘要: 题目 输入一系列整数,将其中最大的数挑出(如果有多个,则挑出一个即可),并将剩下的数进行排序,如果无剩余的数,则输出-1。 代码 1 #include<iostream> 2 #include<algorithm> 3 using namespace std; 4 int main(){ 5 int 阅读全文
posted @ 2021-03-01 17:11 Uitachi 阅读(85) 评论(0) 推荐(0)
摘要: 题目 成绩排序——2000年清华大学计算机机试真题 代码 1 #include<iostream> 2 #include<algorithm> 3 #include<string> 4 using namespace std; 5 typedef struct stu{ 6 char name[10 阅读全文
posted @ 2021-03-01 16:50 Uitachi 阅读(70) 评论(0) 推荐(0)
摘要: 冒泡排序 1 #include<iostream> 2 #include<algorithm> 3 using namespace std; 4 int n; 5 int main(){ 6 int a[100]; 7 while(scanf("%d",&n) != EOF){ 8 for(int 阅读全文
posted @ 2021-03-01 16:13 Uitachi 阅读(45) 评论(0) 推荐(0)