2018 HDU多校第四场赛后补题 自己学校出的毒瘤场..吃枣药丸 hdu中的题号是6332 - 6343. K. Expression in Memories 题意: 判断一个简化版的算术表达式是否合法. 题解: 注意细节即可. 代码: #include <bits/stdc++.h> using namespace std; int n; char s[505]; int main () { int T; cin>>T; for ( ; T; --T) { scanf(&quo…
2018 HDU多校第三场赛后补题 从易到难来写吧,其中题意有些直接摘了Claris的,数据范围是就不标了. 如果需要可以去hdu题库里找.题号是6319 - 6331. L. Visual Cube 题意: 在画布上画一个三维立方体. 题解: 模拟即可. 代码: #include <bits/stdc++.h> using namespace std; int a, b, c, R, C; char g[505][505]; int main () { int T; cin >>…
题目链接 题意:二维平面上有n个点(没有重叠,都不在原点,任意两点连线不过原点),每个点有一个权值,用一条过原点的直线把他们划分成两部分,使两部分的权值和的乘积最大.输出最大的乘积. 极角排序后,将原来(-pi,pi]区间的元素copy到(pi,3pi],用双指针维护一个角度差不超过pi的区间,记区间的权值和为sum1,用sum1*(sum-sum)更新ans #include<bits/stdc++.h> using namespace std; typedef long long LL;…
Problem E. Matrix from Arrays Time Limit: / MS (Java/Others) Memory Limit: / K (Java/Others) Total Submission(s): Accepted Submission(s): Problem Description Kazari has an array A length of L, she plans to generate an infinite matrix M using A. The p…
Problem B. Harvest of Apples Time Limit: / MS (Java/Others) Memory Limit: / K (Java/Others) Total Submission(s): Accepted Submission(s): Problem Description There are n apples on a tree, numbered to n. Count the number of ways to pick at most m apple…