[AtCoder 2702]Fountain Walk - LIS】的更多相关文章

Problem Statement In the city of Nevermore, there are 108 streets and 108 avenues, both numbered from0 to 108−1. All streets run straight from west to east, and all avenues run straight from south to north. The distance between neighboring streets an…
Portal --> agc019C Description 有一个\(10^8*10^8\)的网格图,一格距离为\(100\),第\(x\)条竖线和第\(y\)条横线的交点记为\((x,y)\),有一些点上面有半径为\(10\)的喷泉(一个圆),一行或者一列至多一个喷泉,现在一个人要从\((x1,y1)\)走到\((x2,y2)\),只能沿着网格走,遇到喷泉的话可以沿着边缘走,问最短距离 Solution 一开始看错题以为可以不沿着网格走的我真的是太弱智了.. ​ 因为只能沿着网格走,所以我们…
传送门 题目大意 给定网格图上起点和终点每个格子是长为$100$米的正方形,你可以沿着线走. 平面上还有若干个关键点,以每个关键点为圆心,$10$为半径画圆,表示不能进入圆内的线,但是可以从圆周上走,求起点到终点的最短距离. 保证任意两个关键点不在同一条水平或竖直的线上. 题解 先通过翻转网格图使得起点$S$在终点$Y$的左下方,由于有任意两两关键点不在同一水平竖直的线上,通过简单计算发现,我们只可能往右或往上冲着最终的终点走. 随意我们只需要横纵坐标都在起点终点之间的关键点即可. 对于一个关键…
A - Ice Tea Store 算一下每种零售最少的钱就行,然后优先买2,零头买1 #include <bits/stdc++.h> #define fi first #define se second #define pii pair<int,int> #define mp make_pair #define pb push_back #define space putchar(' ') #define enter putchar('\n') #define MAXN 100…
A - Already 2018 题目链接:https://abc085.contest.atcoder.jp/tasks/abc085_a Time limit : 2sec / Memory limit : 256MB Score : 100 points Problem Statement On some day in January 2018, Takaki is writing a document. The document has a column where the curren…
AtCoder Grand Contest 031 Atcoder A - Colorful Subsequence description 求\(s\)中本质不同子序列的个数模\(10^9+7\).两个子序列不同当且仅当存在一种字符在两者中的出现次数不同. \(|s|\le10^5\) solution \(\prod_{i='a'}^{'z'}(\mbox{字符}i\mbox{出现的次数}+1)-1\) #include<cstdio> #include<algorithm>…
比赛链接:https://atcoder.jp/contests/abc165/tasks A - We Love Golf 题意 区间 $[a, b]$ 中是否存在 $k$ 的倍数. 代码 #include <bits/stdc++.h> using namespace std; int main() { int k, a, b; cin >> k >> a >> b; for (int i = a; i <= b; i++) { if (i % k…
1.[问题]护士站打印LIs条码,出来是PDF格式的 [解决]在文件夹Client\NeusoftLis\Xml\Print.xml中把BarcodePrint Name的值改成安装的斑马打印机名(不带EPL的那个),如下配置: <BarcodePrint Name="ZDesigner GK888t" />…
Prince and PrincessInput: Standard Input Output: Standard Output Time Limit: 3 Seconds In an n x n chessboard, Prince and Princess plays a game. The squares in the chessboard are numbered 1, 2, 3 ... n*n, as shown below: Prince stands in square 1, ma…
os.walk()返回三个参数:os.walk(dirpath,dirnames,filenames) for dirpath,dirnames,filenames in os.walk(): 返回dirnames,filenames的类型为列表list[] 返回的dirpath为filenames的上级路径,如果要获得全路径和文件名,以便open的话,可以用在for filename in filenames的循环下用os.path.join(dirpath,filename)进行拼接…