Problem D:合唱队形 Time Limit:1000MS Memory Limit:65536K Total Submit:1237 Accepted:437 Language: not limited Description N位同学站成一排,音乐老师要请其中的(N-K)位同学出列,使得剩下的K位同学排成合唱队形。 合唱队形是指这样的一种队形:设K位同学从左到右依次编号为1,2…,K,他们的身高分别为T1,T2,…,TK, 则他们的身高满足T1 < T2 < ...< Ti > Ti+1 > … >TK(1<=i<=K)。 你的任务是,已知所有N位同学的身高,计算最少需要几位同学出列,可以使得剩下的同学排成合唱队形。 Input 输入包含若干个测试用例。 对于每个测试用例,输入第一行是一个整数N(2<=N<=100),表示同学的总数。第二行有N个整数,用空格分隔,第i个整数Ti(130<=Ti<=230)是第i位同学的身高(厘米)。当输入同学总数N为0时表示输入结束。 Output 对于每个测试案例,输出包括一行,这一行只包含一个整数,就是最少需要几位同学出列。 Sample Input 8 186 186 150 200 160 130 197 220 3 150 130 140 0 Sample Output 4 1
标签: Limit Accepted Language Problem
上传时间: 2014-01-13
上传用户:aappkkee
Problem F:汽车加油 Time Limit:1000MS Memory Limit:65536K Total Submit:1400 Accepted:404 Language: not limited Description 一辆汽车加满油后可行驶n公里。旅途中有若干个加油站。设计一个有效算法,指出应在哪些加油站停靠加油,使沿途加油次数最少。 编程任务: 对于给定的n和k(k <= 10000)个加油站位置,编程计算最少加油次数。 Input 第一行有2 个正整数n和k,表示汽车加满油后可行驶n公里,且旅途中有k个加油站。接下来的1 行中,有k+1 个整数,表示第k个加油站与第 k-1 个加油站之间的距离。第0 个加油站表示出发地,汽车已加满油。第k+1 个加油站表示目的地。 Output 输出最少加油次数。如果无法到达目的地,则输出”No Solution”。 Sample Input 7 7 1 2 3 4 5 1 6 6 Sample Output 4
标签: Limit Accepted Language Problem
上传时间: 2016-04-12
上传用户:youth25
// This program measures the voltage on an external ADC input and prints the // result to a terminal window via the UART. // // The system is clocked using the internal 24.5MHz oscillator. // Results are printed to the UART from a loop with the rate set by a delay // based on Timer 2. This loop periodically reads the ADC value from a global // variable, Result.
标签: the measures external program
上传时间: 2013-12-27
上传用户:trepb001
AIOTrade is a free, open source stock technical analysis platform built on pure java. Its pluggable architecture is also ideal for custom features extending, such as indicators and charts. It Requires JRE 1.5.0+.
标签: pluggable technical AIOTrade analysis
上传时间: 2014-12-05
上传用户:csgcd001
Offers sound advice on selecting a thesis or postdoctoral adviser, choosing among research jobs in academia, government laboratories, and industry, preparing for an employment interview, and defining a research program.
标签: postdoctoral selecting choosing research
上传时间: 2014-01-20
上传用户:kelimu
Wxpython Implemented on Windows CE, Source code
标签: Implemented Wxpython Windows Source
上传时间: 2016-04-13
上传用户:远远ssad
Fast settling-time added to the already conflicting requirements of narrow channel spacing and low phase noise lead to Fractional4 divider techniques for PLL synthesizers. We analyze discrete "beat-note spurious levels from arbitrary modulus divide sequences including those from classic accumulator methods.
标签: settling-time requirements conflicting already
上传时间: 2016-04-14
上传用户:liansi
A Tutorial on Principal Component Analysis.Principal component analysis (PCA) is a mainstay of modern data analysis - a black box that is widely used but poorly understood. The goal of this paper is to dispel the magic behind this black box.
标签: Principal Component component Tutorial
上传时间: 2016-04-14
上传用户:aysyzxzm
Pixel Labeled Algorithm Based on Recursive M ethod of Connecting Area in Binary Images
标签: Connecting Algorithm Recursive Labeled
上传时间: 2013-12-08
上传用户:refent
WIN CE Draw 2D GRAPHIC EXAMPLE BASED ON VS2005 SMART DEVICE
标签: GRAPHIC EXAMPLE DEVICE BASED
上传时间: 2014-03-07
上传用户:lvzhr