摘要:
A link 模拟整个过程即可。 点击查看代码 #include<bits/stdc++.h> #define int long long using namespace std; signed main(){ int h; cin >> h; int day = 1ll,g = 0ll; whil 阅读全文
摘要:
A link 暴力寻找\(2\)及以后比\(a_1\)大的数。 点击查看代码 #include<bits/stdc++.h> using namespace std; int n; int a[105]; signed main(){ cin >> n; for(int i = 1;i <= n;+ 阅读全文
摘要:
A link \(x\)停不到,\(y\)能停到。 要先判断是从前往后还是从后往前。 点击查看代码 #include<bits/stdc++.h> using namespace std; signed main(){ int n,x,y,z; cin >> n >> x >> y >> z; if 阅读全文
摘要:
A link 其实,只要有第一次,那么下次随意找一个队列里有的数加\(k-1\)个进去,加上队列里那一个删掉\(k\)个,到最后一次肯定是剩\(k-1\)个。 没有第一次,就是\(n\)。 点击查看代码 #include<bits/stdc++.h> using namespace std; int 阅读全文
摘要:
A link 算出两个队分别得了几分,让木青队的总得分比高桥队多\(1\)即可。 点击查看代码 #include<bits/stdc++.h> using namespace std; int gq,mq; signed main(){ int x; for(int i = 1;i <= 9;++ 阅读全文
摘要:
A link 把最后三位取成数字,判断是否小于\(349\),大于\(1\),不等于\(316\)。 点击查看代码 #include<bits/stdc++.h> using namespace std; char s[10]; int ans; signed main(){ cin >> s+1; 阅读全文
摘要:
A link 其实,有人赢比赛,就有人输比赛,一加一减,不管进行多少场比赛,最后所有人的分数和一定是\(0\)。 那么知道\(n-1\)个人的分数和,就可以知道第\(n\)个人的了。 点击查看代码 #include<bits/stdc++.h> using namespace std; int n; 阅读全文
摘要:
A 这个题是一个暴力 判断是否全在对角线上或下,两次二重循环即可,如果是,直接乘起来。 点击查看代码 #include<bits/stdc++.h> #define int long long using namespace std; const int mo = 1e9+7; int n; int 阅读全文