
题解
「已注销」
这个作者很懒,什么都没留下…
展开
-
【HDU】2020杭电多校第十场解题报告(1003、1011)
1003:Mine Sweeper AC代码 #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long long ll; typedef unsigned long long ull; const int maxn = 50; const int INF = 0x3原创 2020-08-20 21:07:32 · 699 阅读 · 0 评论 -
【HDU】 2020暑期杭电多校第八场
1003:Clockwise or Counterclockwise 叉乘: #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long long ll; typedef unsigned long long ull; inline ll gcd(ll a,ll b原创 2020-08-14 10:10:23 · 468 阅读 · 0 评论 -
【HDU】2020暑期杭电多校第7场解题报告(更新中)
1009:Increasing and Decreasing 下面是AC代码: #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long long ll; typedef unsigned long long ull; inline ll gcd(ll a,原创 2020-08-11 20:05:10 · 1278 阅读 · 0 评论 -
2020牛客暑期多校训练营(第十场)解题报告(更新中)
A:Permutation #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long long ll; typedef unsigned long long ull; ll p ; inline ll gcd(ll a,ll b){return b == 0? a原创 2020-08-10 15:02:32 · 1576 阅读 · 3 评论 -
2020牛客暑期多校训练营(第九场)解题报告(正在更新)
A:Groundhog and 2-Power Representation 链接 题意: 朴素的递归思想,模拟从里到外去括号的过程,加上高精度即可AC def x(a): return 2**a str = input() str = str.replace("2(","x(") print(eval(str)) I:The Crime-solving Plan of Groundhog 题意: 给出n个1-9之间的数字,组成两个正整数(不含前导零)求出乘积的最小值。 思路: 只有在一个数字乘上一原创 2020-08-09 09:40:15 · 286 阅读 · 0 评论 -
2020上海高校程序设计竞赛暨第18届上海大学程序设计联赛夏季赛(题解)
传送门 A.同源 这题只需要两个for循环暴力模拟就可以过了 但是有没有大佬在下面讲解一下原理,为什么只要循环到10就能跑出来。。 直接上AC代码: #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long long ll; typedef unsigned lo原创 2020-08-06 10:59:12 · 320 阅读 · 0 评论 -
2020牛客暑期多校 I Interesting Computer Game (并查集+离散化)
I Interesting Computer Game 题意: 有两个数组a , b , 第i步可以从ai bi 中选取一个数,求出最多能获取几个不同的数字 。 下面直接上AC代码: 并查集+离散化 #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long lo原创 2020-08-04 21:45:10 · 154 阅读 · 0 评论 -
[HDU 多校训练] Equal Sentences (2020第四场1005)
HDU Equal Sentences (2020杭电多校训练第四场1005) HDU Equal Sentences 废话不多说直接上AC代码 #include <bits/stdc++.h> #define rep(i,a,b) for(int i=a;i<b;i++) #define T int t ;cin >> t;while(t--) using namespace std ; typedef long long ll; typedef unsigned lon原创 2020-07-30 17:10:07 · 611 阅读 · 0 评论 -
HDU 6799 Parentheses Matching (2020杭电多校训练第三场)
HDU Parentheses Matching 2020 第三场 1009 杭电OJ6799 Problem Description Given a string P consisting of only parentheses and asterisk characters (i.e. “(”, “)” and “"), you are asked to replace all the asterisk characters in order to get a balanced parenthesi原创 2020-07-29 20:33:05 · 303 阅读 · 0 评论