庆祝国庆黑板报,好孩子育儿网,花与蛇小说下载
地址:
problem description
calculate a + b.
input
each line will contain two integers a and b. process to end of file.
output
for each case, output a + b in one line.
sample input
sample output
2
1.我的第一道acm题,非常非常非常简单的一道题
2.但是我还是卡了
3.原因是没有循环输入输出
4.总结:英语非常重要,稍微一点点偏差,会自闭一天
代码:
1 #include <iostream>
2 using namespace std;
3 int main ( )
4 {
5 int x,y;
6 while (cin>>x>>y)
7 cout<<x+y<<endl;
8 return 1;
9 }
如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!!
点击进行留言回复
相关文章:
-
-
C++ 作用域
作用域:名称在翻译单元(包括文件)的可见范围 局部: 只在定义它的代码块中可用,如自动变量 全局(文件作用域): 从定义位置到文件结尾都可用 注意: 静...
[阅读全文]
-
-
-
-
聚合类型与POD类型
Lippman在《深度探索C++对象模型》的前言中写道: I have heard a number of people over the years ...
[阅读全文]
-
-
-
-
-
网友评论