`
jkbjxy
  • 浏览: 82269 次
  • 性别: Icon_minigender_1
  • 来自: 苏州
社区版块
存档分类
最新评论

1000:A+B problem

阅读更多


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
1 1
Sample Output
2

 

import java.util.Scanner;  
public class Main{  
    public static void main(String[] args) {      
        Scanner scan = new Scanner(System.in);  
        while(scan.hasNext())  
        {  
            int i = scan.nextInt();  
            int j = scan.nextInt();  
            System.out.println(i+j);  
        }     
    }  
}  
 

 

 

 

 

 

 

 

 

 

分享到:
评论

相关推荐

    Another A+B Problem

    可以计算任意位数的加法,C++实现,精度可达100位

    A+B Problem

    Description Calculate a+b Input Two integer a,b (0<=a,b) Output Output a+b Sample Input 1 2 Sample Output 3

    洛谷题解:P1001-A+B Problem

    洛谷题解:P1001-A+B Problem

    1000. A+B Problem

    #include using namespace std; int main() { int a,b; cin>>a>>b; cout<<a+b; }

    a+b c语言

    A+B的c语言表示方法.很简单的一个例子仅供参考

    《英语学习工具书总汇》作者:多人

    《英语学习工具书总汇》作者:多人,多本英语工具书的集合!

    A+Bproblem完整代码

    下载超过3次或对应题解文章点赞超过1个便开放免费下载!

    A+B problem问题

    输入A和B,求出A+B的值

    杭电 acmA + B Problem

    在编程的时候供大家参考,希望各位参加 acm的同学好好努力,能够取得好成绩

    hdu 1753 大明A+B

    现在,给你两个正的小数A和B,你的任务是代表大明计算出A+B的值。 Input 本题目包含多组测试数据,请处理到文件结束。 每一组测试数据在一行里面包含两个长度不大于400的正小数A和B。 Output 请在一行里面...

    ZOJ1001 A + B Problem

    NULL 博文链接:https://weitch.iteye.com/blog/1006774

    1. A+B Problem.cpp

    具体题目在我的博文当中

    algoexec:算法练习

    算法练习概述用于提交数据结构课程作业用法对应的译文在/problem/%问题%/problem.md下例如: /problem/A+B Problem/problem.md代码提交在/src/%班级%/%名称%/%问题%/下例如: /src/Class 1/ZhangSan/A+B Problem/a+b...

    ACM题目&答案

    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. ... printf("%d\n",a+b); }

    c++-文件批量处理示范(生成样例)(批量生成文件)

    Problem1000: #include using namespace std; int main(){ int a,b; while(cin>>a>>b){ cout<<a+b; } return 0; } ------------------------------------------------------ 会生成“Problem 1000.txt",内容为...

    杭电ACM-HDUOJ 1001 SUM problem

    杭电ACM第1001题的代码。这个A+B PROBLEM的变形。初学者只要习惯了就好

    大数处理问题(就是用字符串)

    Given two integers A and B, your job is to calculate the Sum of A + B. Input The first line of the input contains an integer T(1 ) which means the number of test cases. Then T lines follow, each ...

    杭电ACM 1002

    Given two integers A and B, your job is to calculate the Sum of A + B. Input The first line of the input contains an integer T(1) which means the number of test cases. Then T lines follow, each ...

    西工大noj答案完整版.doc

    2.A+B 3.A+BⅡ 4.AB 5.ACKERMAN 6.Arithmetic Progressions 7.Bee 8.Checksum algorithm 9.Coin Test 10.Dexter need help 11.Double 12.Easy problem 13.Favorite number 14.Graveyard 15.Hailstone 16.Hanoi Ⅱ 17...

    leetcode和oj-C-Coding:C++源代码

    A+B Problem 基本输入输出 2 big int 超长整数相加 3 link 将两个线性表合并成为一个线性表 4 edit 字符串操作 5 二哥摘苹果 6 二哥种花生 7 二哥养细菌 8 西西弗斯式的命运 9 排序 10 Ackerman函数 11 ackerman 12 ...

Global site tag (gtag.js) - Google Analytics