A + B Problem (1)

时间限制(普通/Java):1000MS/3000MS          运行内存限制:65536KByte
总提交:5907            测试通过:1516

描述

Calculate a + b.

输入

The input will consist of a series of pairs of integers a and b,separated by a space, one pair of integers per line.

输出

For 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.

样例输入

1 5

样例输出

6

题目来源

ZOJ

#include<iostream>
#include<vector>
using namespace std;
int main(){
int i,a,b;
vector<int> ivec;
while(cin>>a>>b)
{
ivec.push_back(a+b);
}
for(i=;i<ivec.size();i++)
cout<<ivec[i]<<endl;
return ;
}

ACM——A + B Problem (1)的更多相关文章

  1. ACM - a + b Problem

    前几天看了ACM的第一题,映入眼帘的是一个“简单”的题目: 输入两个数,a,b 输出他们的和. 本着,此乃ACM的原则,便有了如下的思考: ACM的题目肯定很难,a+b,怎么可能直接printf,不行 ...

  2. ACM: A Simple Problem with Integers 解题报告-线段树

    A Simple Problem with Integers Time Limit:5000MS Memory Limit:131072KB 64bit IO Format:%lld & %l ...

  3. ACM——A + B Problem (4)

    A + B Problem (4) 时间限制(普通/Java):1000MS/3000MS          运行内存限制:65536KByte总提交:2496            测试通过:124 ...

  4. ACM——A + B Problem (3)

    Home Problems 1086 A + B Problem (3) 时间限制(普通/Java):1000MS/3000MS          运行内存限制:65536KByte总提交:2317 ...

  5. ACM——A + B Problem (2)

    A + B Problem (2) 时间限制(普通/Java):1000MS/3000MS          运行内存限制:65536KByte总提交:2600            测试通过:137 ...

  6. 2013年 ACM 有为杯 Problem I (DAG)

    有为杯  Problem I DAG  有向无环图 A direct acylic graph(DAG),is a directed graph with no directed cycles . T ...

  7. ACM程序设计选修课——Problem E:(ds:图)公路村村通(优先队列或sort+克鲁斯卡尔+并查集优化)

    畅通工程 Time Limit: 1000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others) Total Submi ...

  8. ACM程序设计选修课——Problem D: (ds:树)合并果子(最优二叉树赫夫曼算法)

    Problem D: (ds:树)合并果子 Time Limit: 5 Sec  Memory Limit: 64 MB Submit: 80  Solved: 4 [Submit][Status][ ...

  9. 【ACM】hdu_zs3_1008_Train Problem I_201308100835

    Train Problem I Time Limit : 2000/1000ms (Java/Other)   Memory Limit : 65536/32768K (Java/Other)Tota ...

随机推荐

  1. geoserver 安装 sql server 插件

    Did you download and install the sql server plugin as well?   http://downloads.sourceforge.net/proje ...

  2. Linux中link,unlink,close,fclose详解

    每一个文件,都可以通过一个struct stat的结构体来获得文件信息,其中一个成员st_nlink代表文件的链接数.       当通过shell的touch命令或者在程序中open一个带有O_CR ...

  3. 【解决】Microsoft Visual Studio 2012 打开2008下编译的silverlight3项目

    最近因为项目需要,老师要我搞一发流程设计器,毫无头绪呀妈蛋 .. 我考虑是用silverlight呢还是jquery .. 上网找了找  .. 有一个用silverlight3写的 貌似IDE用的是V ...

  4. 最简单的基于FFMPEG的音频编码器(PCM编码为AAC)

    http://blog.csdn.net/leixiaohua1020/article/details/25430449 本文介绍一个最简单的基于FFMPEG的音频编码器.该编码器实现了PCM音频采样 ...

  5. 问题-delphi 调试(F8)错行处理

    在delphi 7中(其他版本也可能碰到该问题),编译后,代码左边显示蓝色小点,表示哪句代 码是被编译了的,可今天我的一些代码不能显示那些蓝点了,这样也就不能在上面设断点了,而且用F8跟踪发现执行的顺 ...

  6. clock_t与time_t的区别及联系

    clock_t <ctime> Clock type Type capable of representing clock tick counts and support arithmet ...

  7. hdoj 1532 Drainage Ditches【最大流模板题】

    Drainage Ditches Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) ...

  8. Script.NET Perl解释器代码已经在GitHub开源发布

    Script.NET Perl解释器的代码已经提交到GitHub网站.GitHub项目地址: https://github.com/blueantst/Script.NET Perl解释器代码在Src ...

  9. oc学习之路----QQ聊天界面

    用到的技术:自定义cell,通知机制,代理模式 transform 1.自定义cell(通过代码自定义cell) ①首先新建一个类继承UITableViewCell ②重写initWithStyle: ...

  10. Eclipse + Pydev 配置Python开发环境

    之前有人问 Eclipse + Pydev 的环境配置问题,在此记录一下. 前提条件:需要安装 Eclipse .jdk.Python.这三个软件都可以在官网上下载. 假设上述软件已经安装好了,下面是 ...