随笔分类 - ATcoder
摘要:A - abc of ABC #include <bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; char a[5]; int main() { for (int i = 0; i <
阅读全文
摘要:A - Cats and Dogs #include<bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; int a, b, c; int main(){ cin >> a >> b >>
阅读全文
摘要:A - Something on It #include <bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; int sum = 700; int main() { string s; c
阅读全文
摘要:A - Day of Takahashi 输入a b,问从1月1号到a月b号有几天是月份和日期相同的 #include<bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; int a, b;
阅读全文
摘要:A - Colorful Transceivers 给出abcd四个数,abc都是一维坐标,问a能否和c直接或间接联通,坐标差值在d以内的可以直接联通 直接模拟即可 #include<bits/stdc++.h> using namespace std; const int N = 1e6 + 5;
阅读全文
摘要:A - Add Sub Mul 输出加减乘的最大值 #include<bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; int a, b; int main(){ cin >> a >>
阅读全文
摘要:A - ABD 大意: 输入1-999就输出ABC,否则输出ABD #include<bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; int n; int main(){ cin >>
阅读全文
摘要:A - Happy Birthday! 大意: 一个蛋糕分为16份,A和B各自需要拿a和b份,问能否使得每个人拿到的蛋糕都是不连续的: 思路: 先把较少的蛋糕数一一对应相隔,然后判断剩下的能否隔一个取一个即可 #include<bits/stdc++.h> using namespace std;
阅读全文
摘要:A - Eating Symbols Easy 大意: 一开始是0,四个符号,-是-1,+是+1 #include<bits/stdc++.h> using namespace std; const int N = 1e6 + 5; typedef long long LL; string s; i
阅读全文
摘要:A Takoyaki 大意: 一次可以做x个饼,每次花t分钟,问做n个饼花多少分钟 思路: 向上取整即可,注意要用double强制转换一下 #include <bits/stdc++.h> using namespace std; typedef long long LL; typedef pair
阅读全文

浙公网安备 33010602011771号