




已阅读5页,还剩5页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
DescriptionIn our high school, we had learn a theorem: if two numbers have the invariablenes sum, they will get the maximum product when they are equal, on the side, another is if two numbers have the invariablenes product, they will get the minimum sum when each of them equals the other one.Now, I will give you a same equations, you should give me the result that you can get from the above theorems.InputThere are several test cases. Each case contains a string, it is an equation, and its length is less than 1024. In the equation, the variants are different, and only contain lower letters, the number is a legality double number variants , operator sign and number are separate by spaces.OutputOutput the result that you can get from the two theorems(the result is rounded to two decimal digits). And the result should express as ranges, ranges will be united by letter U, each range have a left value and a right value and the range should begin with ( and end with ), if the value is infinite it should be replace with inf, all numbers, signs, values should separate by space.Sample Inputx + y = -4.00a * b = 4.0401s * t = -0.000i * j = 0.01Sample Output(-inf x * y = 4.00)(-inf a + b = -4.02) U (4.02 = a + b +inf)(-inf s + t +inf)(-inf i + j = -0.20) U (0.20 = i + j +inf)DescriptionOne day, XiaoA is calculating an upright expression(A is not zero):ABCD*) 9-DCBAHe found the answer is ABCD=1089, and then, he think about a hard question (it is below), what is the answer?ABCDEFGH.RST*) X-TSR.HGFEDCBAInputThere are several test cases. Each case contains two integer L and X, L indicates the length of the variant above and X is the value of the factor (0L=1024, 0=X=9).OutputYou should output the solution for the upright expression, if there is more than one solution, you should output the minimum solution, and if there is not solution, you should output No solutionSample Input4 96 53 1Sample Output1089No solution101HintThe different letters can indicate same number.DescriptionWe define that if Integer X and N satisfy that : X*X = N (X+1)*(X+1), X can be called as the root of N. Now, I give you a integer N, you should tell me what is the root of it, and the result is binary digits.InputThere are several test cases, each case contains an Integer N(0=N=10200)# indicates the end of input.OutputOutput the root of input in binary digits.Sample Input456100#Sample Output1010101010DescriptionHank was potty about Rubiks cube; Rubiks cube is an intelligence toy. Hank spent hours each day exercising, so the Rubiks cube breaks frequently. Hank had to buy new Rubiks cube often.Today, hank buys a new Rubiks cube, and it is chaotic. Can you help him to find the colors in opposite faces?InputThere are several test cases; the first integer T indicates the number of test cases. Each case includes an integer N and six blocks, N indicates the rank of the Rubiks cube(1=N=11), and the six blocks indicate the colors of the six faces of the Rubiks cube.OutputOutput the case number and the pairs of colors in order of B, G, O, R, W, Y, like this:B-opposite-face-colorG-opposite-face-colorO-opposite-face-colorR-opposite-face-colorW-opposite-face-colorY-opposite-face-colorAfter each case there is a blank line.Sample Input12YYYYOOOOBBBBRRRRGGGGWWWWSample OutputCase #1:B-GG-BO-RR-OW-YY-WDescriptionXiaoz teacher gives him a very hard problem. Teacher gives him two strings S, T, and asks xiaz judge that if string S is a substring in string T, xiaoz is exultingly, because The KMP algorithm is suitable, but then teacher says, if string T has a substring which can become string S by edit some characters, it is also accept. This problem makes xiaoz be headache, so he ask for your help.InputThere are several test cases. In each case, the first line contains an integer k(K=100), indicate themaximumtimes you can edit with string T. Then the second line contains a string, indicate string S, and the third line contains a string, indicate string T. Both of lengths of the strings will be less than 10010.OutputIf the string S can be the substring of string T by editing string T andno more than Ktimes then print YES! else print NO!.Sample Input2annualannealingSample OutputYES!DescriptionGeometry transformation is a widely used technology in computer graphics. The problem you need to solve today is to compute the area of the cubic projection. Refer to the following Fig.1, the projection of the cube on face xoy is shown as the grey area on xoy.Fig.1 A simple example of projectionIn graphical processing, rotation around a line is a foundational operation. Fig.2 gives an example. In Fig.2, the right cube is obtained by rotating the left cube counterclockwise around vector L by 180 degrees.Fig.2 A rotation exampleGive a cube C, a vector L and an angle A, your job is to calculate the area of the projection of C on face xoy after rotating cube C counterclockwise around vector L by angle A degree. The cubes are always given with edge w parallel to x-axis, edge h parallel to y-axis and edge l parallel to z-axis, same as Fig.1. So a known side length and a known coordinate of vertex p can determine the cube. Vertex p is the closest vertex to point o.InputWe test the problem in many cases. The first line is the number of test cases. In each case, the side length of the cube and the coordinate of vertex p are give first. Following that is the vector L. vector L is given as the form of start coordinate and the end coordinate. Finally, the angle A is presented. All the numbers given are integers and are in interval -10000, 10000.OutputThe output consists of the areas of all the projection. The results must be round to 2 decimal numbers.Sample Input2205 5 50 15 15 -15 15 15315100 0 00 0 0 10 10 10275Sample Output565.69148.80DescriptionNowadays, the society is developed economy, and consumes a lot of resources, especially the oil.Now, some pipes transport oil from city A to city B for the consuming of city B, but the distance from city A to city B is too long, there are many transfer stations, and K levels among the transfer stations, city A and city B, city A is level 1, and city B is level K, and the levels of transfer stations are between 2 and k-1, and only the transfer stations which has consecutive levels can be connected.We know all the volumes of the pipes, the citymaster of city B employs builders to expand some pipes, avoid the leavings in pipes, but the builders hope the less expandedness the better, achieve the require of the citymaster of city B minimally.The citymaster of city B want know the values of the flow before and after the expansion.In figure, the values of the flow before and after the expansion is 2 and 4.Inp
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 成都市商品房买卖合同书6篇
- 青储饲料设备代销协议7篇
- 公司员工培训合同书5篇
- 《中华民族一家亲》第一课时 +公开课一等奖创新教学设计
- 1公民基本权利 议题式公开课一等奖创新教学设计 统编版道德与法治八年级下册
- 2025劳动合同范本(参考)
- 合同范本技术改造借款合同3篇
- 老年人窒息抢救课件
- 2025超市员工劳动合同模板
- 高中政治 2.1君主立宪制和民主共和制说课稿 新人教版选修3
- DL∕T 5461.11-2013 火力发电厂施工图设计文件内容深度规定 第11部分土建结构
- CB-Z-239-1987一般排水量船模双桨自航试验方法
- 篮球教学活动设计方案
- 平安经营分析岗面试
- 西方节日-英文介绍
- 空调系统维保记录簿表
- 动车组列车员(长)(职业通用)全套教学课件
- 医学影像技术职业生涯规划
- 义务教育物理课程标准(2022年版)测试题文本版(附答案)
- 牙本质过敏症课件
- 未成年人保护法宣传教育
评论
0/150
提交评论