摘要: 测试点6:存在不属于链内的结点 1 #include <iostream> 2 #include <algorithm> 3 using namespace std; 4 5 struct node{ 6 int id, val, next; 7 }; 8 9 int main(){ 10 int 阅读全文
posted @ 2022-01-18 13:59 千咲 阅读(102) 评论(0) 推荐(0)
摘要: 测试点4、5:确保最后一位没有非大写字母输出的时候,最后一个单词输出完整 测试点2、3:确保最后多位都是非大写字母输出的时候,不多输出一个空格 未测试的内容:未出现大写字母前是否出现非大写字母 1 #include <iostream> 2 using namespace std; 3 4 int 阅读全文
posted @ 2022-01-18 11:41 千咲 阅读(130) 评论(0) 推荐(0)
摘要: 1 #include <iostream> 2 using namespace std; 3 4 int main(){ 5 int nums[6] = {0}; 6 char ss[6] = {'S', 't', 'r', 'i', 'n', 'g'}; 7 string str; 8 cin > 阅读全文
posted @ 2022-01-18 10:30 千咲 阅读(55) 评论(0) 推荐(0)
摘要: 1 #include <iostream> 2 #include <algorithm> 3 using namespace std; 4 5 int main(){ 6 int N, M, data; 7 cin >> N >> M; 8 int max[N] = {0}; 9 for(int i 阅读全文
posted @ 2022-01-18 10:18 千咲 阅读(35) 评论(0) 推荐(0)
摘要: 1 #include <iostream> 2 using namespace std; 3 4 int main(){ 5 int num, res = 0; 6 cin >> num; 7 int data[num] = {2, 0, 1, 9}; 8 for(int i = 0; i < nu 阅读全文
posted @ 2022-01-18 10:13 千咲 阅读(35) 评论(0) 推荐(0)
摘要: 可以直接在函数内输出而不返回出来。 1 #include <iostream> 2 #include <algorithm> 3 using namespace std; 4 5 struct node{ 6 int ad, next, value; 7 }; 8 9 void backs(node 阅读全文
posted @ 2022-01-18 09:43 千咲 阅读(83) 评论(0) 推荐(0)
摘要: 注意整型长度即可。 1 #include <iostream> 2 #include <math.h> 3 using namespace std; 4 5 int main(){ 6 long a, b, c, d; 7 bool flag = false, zong = false; 8 cin 阅读全文
posted @ 2022-01-17 14:47 千咲 阅读(49) 评论(0) 推荐(0)
摘要: 测试点1需要注意只存在一种试卷且销量为0的情况。 #include <iostream> using namespace std; int main(){ string amax, emax, str; int n, aamax = -1, eemax = -1, num, data; cin >> 阅读全文
posted @ 2022-01-17 14:29 千咲 阅读(93) 评论(0) 推荐(0)
摘要: 通过字符串和整型的转换实现。 1 #include <iostream> 2 #include <math.h> 3 using namespace std; 4 5 int main(){ 6 string ss; 7 int a, b, c = 1, d, e, n; 8 cin >> ss > 阅读全文
posted @ 2022-01-17 14:21 千咲 阅读(66) 评论(0) 推荐(0)
摘要: 重点在于用map将id和是否是校友一一对应。 1 #include <iostream> 2 #include <map> 3 using namespace std; 4 5 int main(){ 6 int N, num = 0; 7 string str, old, olb; 8 bool 阅读全文
posted @ 2022-01-17 11:53 千咲 阅读(69) 评论(0) 推荐(0)