摘要: Programmers often have a preference among program constructs. For example, some may prefer if(0==a), while others may prefer if(!a). Analyzing such pa 阅读全文
posted @ 2019-09-11 11:02 zjxxcn 阅读(325) 评论(0) 推荐(0) 编辑
摘要: Eva would like to make a string of beads with her favorite colors so she went to a small shop to buy some beads. There were many colorful strings of b 阅读全文
posted @ 2019-09-11 11:02 zjxxcn 阅读(283) 评论(0) 推荐(0) 编辑
摘要: After finishing her tour around the Earth, CYLL is now planning a universal travel sites development project. After a careful investigation, she has a 阅读全文
posted @ 2019-09-11 11:02 zjxxcn 阅读(1168) 评论(0) 推荐(0) 编辑
摘要: As the manager of your company, you have to carefully consider, for each project, the time taken to finish it, the deadline, and the profit you can ga 阅读全文
posted @ 2019-09-11 11:02 zjxxcn 阅读(267) 评论(0) 推荐(0) 编辑
摘要: It is vitally important to have all the cities connected by highways in a war. If a city is conquered by the enemy, all the highways from/toward that 阅读全文
posted @ 2019-09-11 11:02 zjxxcn 阅读(566) 评论(0) 推荐(0) 编辑
摘要: 裸题: 扩展欧拉定理的应用 1 #include<bits/stdc++.h> 2 using namespace std; 3 int ph(int x){ 4 int ret=x; 5 for(int i=2;i*i<=x;i++) 6 if(x%i==0){ 7 ret=ret/i*(i-1) 阅读全文
posted @ 2019-09-11 11:01 zjxxcn 阅读(138) 评论(0) 推荐(0) 编辑
摘要: Description 给出一个N个点的树,找出一个点来,以这个点为根的树时,所有点的深度之和最大 给出一个N个点的树,找出一个点来,以这个点为根的树时,所有点的深度之和最大 Input 给出一个数字N,代表有N个点.N<=1000000 下面N-1条边. 给出一个数字N,代表有N个点.N<=100 阅读全文
posted @ 2019-09-11 10:59 zjxxcn 阅读(121) 评论(0) 推荐(0) 编辑
摘要: Description Input Output 输出test行,每行一个整数,表示答案。 输出test行,每行一个整数,表示答案。 Sample Input 1 2 2 2 3 1 Sample Output 3 HINT Test<=50 Pi<=10^5,1<=Q1<=10^9 1 #incl 阅读全文
posted @ 2019-09-11 10:58 zjxxcn 阅读(105) 评论(0) 推荐(0) 编辑
摘要: Description Informatikverbindetdichundmich. 信息将你我连结。B君希望以维护一个长度为n的数组,这个数组的下标为从1到n的正整数。一共有m个操作,可以 分为两种:0 l r表示将第l个到第r个数(al,al+1,...,ar)中的每一个数ai替换为c^ai, 阅读全文
posted @ 2019-09-11 10:56 zjxxcn 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 根据一些书上的记载,上帝的一次失败的创世经历是这样的: 第一天, 上帝创造了一个世界的基本元素,称做“元”。 第二天, 上帝创造了一个新的元素,称作“α”。“α”被定义为“元”构成的集合。容易发现,一共有两种不同的“α”。 第三天, 上帝又创造了一个新的元素,称作“β”。“β”被定义为“α”构成的集 阅读全文
posted @ 2019-09-11 10:51 zjxxcn 阅读(184) 评论(0) 推荐(0) 编辑