Maximum Multiple Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3313 Accepted Submission(s): 1382 Problem Description Given an integer n, Chiaki would like to find three positive integers x,…
学长好久之前讲的,本来好久好久之前就要写题解的,一直都没写,懒死_(:з」∠)_ Senior Pan Time Limit: 12000/6000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 1332 Accepted Submission(s): 533 Problem Description Senior Pan fails in his discrete ma…
Problem Description Professor Zhang has a number sequence a1,a2,...,an. However, the sequence is not complete and some elements are missing. Fortunately, Professor Zhang remembers some properties of the sequence: 1. For every i∈{1,2,...,n}, 0≤ai≤100.…
Problem Description 有一群人,打乒乓球比赛,两两捉对撕杀,每两个人之间最多打一场比赛.球赛的规则如下:如果A打败了B,B又打败了C,而A与C之间没有进行过比赛,那么就认定,A一定能打败C.如果A打败了B,B又打败了C,而且,C又打败了A,那么A.B.C三者都不可能成为冠军.根据这个规则,无需循环较量,或许就能确定冠军.你的任务就是面对一群比赛选手,在经过了若干场撕杀之后,确定是否已经实际上产生了冠军. Input 输入含有一些选手群,每群选手都以一个整数n(n<1000)…
题目:传送门. 题意:题目说的是求期望,其实翻译过来意思就是:一个长度为 n 的数列(n>=3),按顺序删除其中每一个数,每次删除都是建立在最原始数列的基础上进行的,算出每次操作后得到的新数列的相邻两数的差的绝对值的最大值,求这些n个最大值的总和. 题解:把n=3的情况单独拿出来直接算出来,就是abs(data[3]-data[2])+abs(data[2]-data[1])+abs(data[3]-data[1]),然后讨论n>=4的情况.首先遍历求出原始数列的相邻两数的差的绝对值的最大值m…
Problem Description We send a light from one point on a mirror material circle,it reflects N times and return the original point firstly.Your task is calcuate the number of schemes. ![](../../data/images/C628--.jpg) Input First line contains a sing…
统计问题 Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 8705 Accepted Submission(s): 5157 Problem Description 在一无限大的二维平面中,我们做如下假设: 1. 每次只能移动一格: 2. 不能向后走(假设你的目的地是“向上”,那么你可以向左走,可以向右走,也可以向上走,但是不…
题目链接: http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=2818 题目描述: Given positive integers B and N, find an integer A such that AN is as close as possible to B. (The result A is an approximation to the Nth root of B.) Note that AN may be l…
中位数计数 Time Limit: 12000/6000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 764 Accepted Submission(s): 309 Problem Description 中位数定义为所有值从小到大排序后排在正中间的那个数,如果值有偶数个,通常取最中间的两个数值的平均数作为中位数. 现在有n个数,每个数都是独一无二的,求出每个数在多少个包…
Delicious Apples Time Limit: 5000/3000 MS (Java/Others) Memory Limit: 524288/524288 K (Java/Others) Total Submission(s): 555 Accepted Submission(s): 180 Problem Description There are n apple trees planted along a cyclic road, which is L metres…
过程很美妙啊 Problem Description Rikka is a high school girl suffering seriously from Chūnibyō (the age of fourteen would either act like a know-it-all adult, or thinks they have special powers no one else has. You might google it for detailed explanation)…
学长讲座讲过的,代码也讲过了,然而,当时上课没来听,听代码的时候也一脸o((⊙﹏⊙))o 我的妈呀,语文不好是硬伤,看题意看了好久好久好久(死一死)... 数学+思维题,代码懂了,也能写出来,但是还是有一点不懂,明天继续. 感谢我的队友不嫌弃我是他的猪队友(可能他心里已经骂了无数次我是猪队友了_(:з」∠)_ ) Function Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Other…