《程序设计竞赛》PPT课件.pptx

上传人:xin****828 文档编号:20799459 上传时间:2021-04-18 格式:PPTX 页数:46 大小:1.53MB
收藏 版权申诉 举报 下载
《程序设计竞赛》PPT课件.pptx_第1页
第1页 / 共46页
《程序设计竞赛》PPT课件.pptx_第2页
第2页 / 共46页
《程序设计竞赛》PPT课件.pptx_第3页
第3页 / 共46页
资源描述:

《《程序设计竞赛》PPT课件.pptx》由会员分享,可在线阅读,更多相关《《程序设计竞赛》PPT课件.pptx(46页珍藏版)》请在装配图网上搜索。

1、 ACM:Association for Computing Machinery 美国计算机协会 ICPC:International Collegiate Programming Contest 国际大学生程序设计竞赛 ACM/ ICPC 由美国计算机协会主办的国际大学生程序设计竞赛ACM/ICPC 是世界上公认的历史悠久、规模最大、水平最高的国际大学生程序设计竞赛。 5 6 如何比赛? 3人 组 队 7 9 如 何 排 名 ? 10 11 12 C:scanf 速 度 快 printf 格 式 容 易 控 制 C+: cin 使 用 简 单 , 自 动 识 别 类 型 cout 格 式 控

2、 制 较 麻 烦数 据 规 模 较 大 时 , 推 荐 (必 须 )使 用scanf 以 避 免 超 时 (TLE)C和 C+的 输 入 输 出 混 合 使 用 29 30Problem DescriptionYour task is to Calculate a + b.Too easy?! Of course! I specially designed the problem for ACM beginners. You must have found that some problems have the same titles with this one, yes, all these

3、 problems were designed for the same aim. InputThe input will consist of a series of pairs of integers a and b, separated by a space, one pair of integers per line. OutputFor each pair of input integers a and b you should output the sum of a and b in one line, and with one line of output for each li

4、ne in input. Sample Input1 510 20Sample Output630 31 32 33 34Problem DescriptionYour task is to Calculate a + b.InputInput contains an integer N in the first line, and then N lines follow. Each line consists of a pair of integers a and b, separated by a space, one pair of integers per line. OutputFo

5、r each pair of input integers a and b you should output the sum of a and b in one line, and with one line of output for each line in input. Sample Input21 510 20Sample Output630 35 for( i=0 ; in ; i+ ) 36 Problem DescriptionYour task is to Calculate a + b.InputInput contains multiple test cases. Eac

6、h test case contains a pair of integers a and b, one pair of integers per line. A test case containing 0 0 terminates the input and this test case is not to be processed.OutputFor each pair of input integers a and b you should output the sum of a and b in one line, and with one line of output for ea

7、ch line in input. Sample Input1 510 200 0Sample Output630 Problem DescriptionYour task is to Calculate the sum of some integers.InputInput contains multiple test cases. Each test case contains a integer N, and then N integers follow in the same line. A test case starting with 0 terminates the input

8、and this test case is not to be processed.OutputFor each group of input integers you should output their sum in one line, and with one line of output for each line in input. Sample Input4 1 2 3 45 1 2 3 4 50 Sample Output1015 Problem DescriptionYour task is to calculate the sum of some integers.Inpu

9、tInput contains an integer N in the first line, and then N lines follow. Each line starts with a integer M, and then M integers follow in the same line. OutputFor each group of input integers you should output their sum in one line, and with one line of output for each line in input. Sample Input24

10、1 2 3 45 1 2 3 4 5Sample Output1015 Problem DescriptionYour task is to calculate the sum of some integers.InputInput contains multiple test cases, and one case one line. Each case starts with an integer N, and then N integers follow in the same line. OutputFor each test case you should output the su

11、m of N integers in one line, and with one line of output for each line in input. Sample Input4 1 2 3 45 1 2 3 4 5Sample Output1015 Problem DescriptionYour task is to Calculate a + b.InputThe input will consist of a series of pairs of integers a and b, separated by a space, one pair of integers per l

12、ine. OutputFor each pair of input integers a and b you should output the sum of a and b, and followed by a blank line. Sample Input1 510 20Sample Output630 Problem DescriptionYour task is to calculate the sum of some integers.InputInput contains an integer N in the first line, and then N lines follo

13、w. Each line starts with a integer M, and then M integers follow in the same line. OutputFor each group of input integers you should output their sum in one line, and you must note that there is a blank line between outputs.Sample Input34 1 2 3 45 1 2 3 4 53 1 2 3Sample Output10 156 43 最 好 不 要 进 行 函

14、 数 声 明 变 量 定 义 在 使 用 之 前 避 免for(int i = 0;i n ;i+) i的 使 用 范 围 仅 仅 在 for内 部 , 容 易 导 致 CE 遇 到 问 题 首 先 自 己 查 找 资 料 , 之 后 再 提 问 44Problem DescriptionGive you an operator (+,-,*, / -denoting addition, subtraction, multiplication, division respectively) and two positive integers, your task is to output th

15、e result. Is it very easy? Come on, guy! PLMM will send you a beautiful Balloon right now!Good Luck!InputInput contains multiple test cases. The first line of the input is a single integer T (0 T1 0 0 0 ) which is the number of test cases. T test cases follow. Each test case contains a char C (+,-,*

16、, /) and two integers A and B(0 A,B1 0 0 0 0 ).Of course, we all know that A and B are operands and C is an operator. OutputFor each case, print the operation result. The result should be rounded to 2 decimal places If and only if it is not an integer.Sample Input4+ 1 2- 1 2* 1 2/ 1 2Sample Output3-120.50 45有什么问题?

展开阅读全文
温馨提示:
1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
2: 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
3.本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
关于我们 - 网站声明 - 网站地图 - 资源地图 - 友情链接 - 网站客服 - 联系我们

copyright@ 2023-2025  zhuangpeitu.com 装配图网版权所有   联系电话:18123376007

备案号:ICP2024067431-1 川公网安备51140202000466号


本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。装配图网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知装配图网,我们立即给予删除!