2020-2021 "Orz Panda" Cup Programming Contest 比赛情况 我们一共过了道3题 本场贡献:et3_tsy :过了A,提供了H的关键修改 ​ 1427314831a:尝试写E,可惜没过 ​ Ryker0923 :过了H,I 罚时:H,I各罚了一次 比赛总结 et3_tsy 这场比赛是比较考验基本功的,像CG,需要的知识储备很低,但是场上没有写,说明还是有点问题的. 1427314831a 多注意一些容易导致死循环的细节. Ryker0923 注意…
My birthday is coming up and traditionally I'm serving pie. Not just one pie, no, I have a numberN of them, of various tastes and of various sizes. F of my friends are coming to my party and each of them gets a piece of pie. This should be one piece…
I Jigsaw 题目内容: 链接:https://ac.nowcoder.com/acm/contest/18454/I 来源:牛客网 You have found an old jigsaw puzzle in the attic of your house, left behind by the previous occupants. Because you like puzzles, you decide to put this one together. But before you…
大大出的题 大大经常吐槽没有人补,所以我决定做一个 A. APA of Orz Pandas 题意:给你一个包含+-*/%和()的表达式,让你把它转化成java里BigInteger的形式 大概就像这样 "a.add(b).remainder(M).multiply(d.substract(e.multiply(f)).add(g.divide(h))).multiply (BigInteger.ValueOf(233)) ... ..." 输入的串长度<=1000 有意思的模拟…
G. The jar of divisors time limit per test:2 seconds memory limit per test:64 megabytes input:standard input output:standard output Alice and Bob play the following game. They choose a number N to play with. The rules are as follows: - They write eac…
Ancient Go Time Limit: 3000/1000 MS (Java/Others)    Memory Limit: 65535/65535 K (Java/Others)Total Submission(s): 577    Accepted Submission(s): 213 Problem Description Yu Zhou likes to play Go with Su Lu. From the historical research, we found that…
#include<bits/stdc++.h> using namespace std; typedef long long ll; int n,m; ; struct node { int team; int num; int time; int id; }a[maxn]; int ans[maxn]; int b[maxn]; int c[maxn]; int s[maxn]; int team[maxn]; int tree[maxn]; int pre[maxn]; int lowbi…
提交链接 http://codeforces.com/gym/100781/submit Description: Ada, Bertrand and Charles often argue over which TV shows to watch, and to avoid some of their fights they have finally decided to buy a video tape recorder. This fabulous, new device can reco…
题目大意:给定一棵 N 个点的树,边有边权,定义"线树"为一个图,其中图的顶点是原树中的边,原树中两条有公共端点的边对应在线图中存在一条边,边权为树中两条边的边权和,求线图的最小生成树的代价是多少. 题解: 对于树中的一个顶点来说,假设有 M 条边以该顶点为一个端点,那么这 M 条边对应到线图中的顶点必须要求能够构成一个联通块.另外,可以发现这个问题的解决和其他顶点无关,即:对于树上每个顶点来说,构成了一个子问题.因此,考虑一个贪心策略,即:每次用边权最小的那条边和其他所有边相连,这样…
题目大意:NOIP2018d1t1 支持 M 次区间查询答案和区间修改操作. 题解: 首先考虑不带区间修改的情况.从左到右进行考虑,发现对于第 i 个数来说,对答案的贡献仅仅取决于第 i-1 个数的大小:若 \(a_i \le a_{i-1}\),则第 i 个数对答案的贡献为 0,否则对答案的贡献为两者的差值.贡献可以这样算是因为每个点至少增加 \(a_i\) 次,且当前点增加多少仅对后面一个数有直接影响.因此,考虑维护差分数组即可,区间修改变成两次单点修改,区间查询转变成查询区间大于 0 的数…