Input The first line of the input contains a single integer T (1 <= T <= 20), the number of test cases. Then T cases follow. The first line of each case contains N, and the second line contains N integers giving the time for each people to cross the river. Each case is preceded by a blank line. There won t be more than 1000 people and nobody takes more than 100 seconds to cross. Output For each test case, print a line containing the total number of seconds required for all the N people to cross the river. Sample Input 1 4 1 2 5 10 Sample Output 17
标签: the contains integer number
上传时间: 2015-10-27
上传用户:plsee
Input The input contains blocks of 2 lines. The first line contains the number of sticks parts after cutting, there are at most 64 sticks. The second line contains the lengths of those parts separated by the space. The last line of the file contains zero. Output The output should contains the smallest possible length of original sticks, one per line. Sample Input 9 5 2 1 5 2 1 5 2 1 4 1 2 3 4 0 Sample Output 6 5
标签: contains The blocks number
上传时间: 2015-10-27
上传用户:lepoke
Input The input consists of two lines. The first line contains two integers n and k which are the lengths of the array and the sliding window. There are n integers in the second line. Output There are two lines in the output. The first line gives the minimum values in the window at each position, from left to right, respectively. The second line gives the maximum values. Sample Input 8 3 1 3 -1 -3 5 3 6 7 Sample Output -1 -3 -3 -3 3 3 3 3 5 5 6 7
上传时间: 2014-12-21
上传用户:hongmo
Solutions are obtained for Poissson, diffusion, or wave PDEs homogeneous or nonhomogeneous equations and/or boundary conditions rectangular, cylindrical, or spherical coordinates time, Laplace, or frequency domains Dirichlet, Neumann, Robin, singular, periodic, or incoming/outgoing boundary conditions. Output is suitable for pasting into LaTeX documents.
标签: nonhomogeneous homogeneous Solutions diffusion
上传时间: 2015-10-30
上传用户:JasonC
design LP,HP,B S digital Butterworth and Chebyshev filter. All array has been specified internally,so user only need to input f1,f2,f3,f4,fs(in hz), alpha1,alpha2(in db) and iband (to specify the type of to design). This program output hk(z)=bk(z)/ak(z),k=1,2,..., ksection and the freq.
标签: Butterworth internally Chebyshev specified
上传时间: 2015-11-08
上传用户:253189838
% 文件名:randlsbget.m % 程序员:余波 % 编写时间:2007.6.25 % 函数功能: 本函数将完成提取隐秘于上的秘密信息 % 输入格式举例:result=( scover.jpg ,56, secret.txt ,2001) % 参数说明: % output是信息隐藏后的图象 % len_total是秘密信息的长度 % goalfile是提取出的秘密信息文件 % key是随机间隔函数的密钥 % result是提取的信息 function result=randlsbget(output,len_total,goalfile,key) ste_cover=imread(output) ste_cover=double(ste_cover) % 判断嵌入信息量是否过大 [m,n]=size(ste_cover) frr=fopen(goalfile, a ) % p作为信息嵌入位计数器将信息序列写回文本文件 p=1 % 调用随机间隔函数选取像素点 [row,col]=randinterval(ste_cover,len_toal,key) for i=:len_toal if bitand(ste_cover(row(i),col(i)),1)==1 fwrite(frr,1, bit1 ) result(p,1) else fwrite(frr,0, bit1 ) result(p,1)=0 end if p==len_total break end p=p+1 end fclose(frr)
标签: randlsbget result scover 2007
上传时间: 2015-11-10
上传用户:yzhl1988
Mobile phones are constantly decreasing in size, thereby complicating the acoustical functionality. Signal processing methods can be used to partially mitigate this problem. In this paper we suggest a method which uses multiple spectral subtraction functions and two microphones, introducing only a short signal delay.
标签: functionality complicating acoustical constantly
上传时间: 2015-11-15
上传用户:youth25
These two classes show an extremely simple example of java.net socket programming. They implement the Unix daytime protocol, an extremely simple protocol that consists entirely of the server sending its current local time and date to the client as an ASCII string. The server, to keep it very simple, does not use multiple threads. This code requires JDK 1.1 or later, but can easily be adapted to JDK 1.0.
标签: programming extremely implement classes
上传时间: 2015-11-16
上传用户:jennyzai
本装置是一个以HT46R71D 为主芯片,配合传感器组成的汽车轮胎气压检测装 置,最终取高三位有效值于LCD 显示,有四种显示单位供切换(Psi、Bar、Kpa、 Kgf/cm2)。本装置仅为参考范例,使用时,为提高准确度,建议多量测些组数 据来构建Sensor Output Voltage - Discharge Time (V-T)表格,并作相应校准。
上传时间: 2015-11-19
上传用户:shinesyh
的问题.派尔高协议,控制左转右转时,出现问题.其他功能好用.我用DELPHI写的程序,在MOUSEDOWN中, str := chr($FF)+chr($01)+chr($00)+chr($04)+chr($0F)+chr($00)+chr($14) MSComm1.output := str 在CLICK事件中: str := chr($FF)+chr($01)+chr($00)+chr($00)+chr($00)+chr($00)+chr($01) MSComm1.output := str
上传时间: 2015-11-20
上传用户:Thuan