POJ ACM习题【No.1000】:示例

a加b

Time Limit :1000MS

Memory Limit :10000K

 

Description

Calculate a+b

Input

Two integer a,b (0<=a,b<=10)

Output

Output a+b

Sample Input

1 2

 

Sample Output

3

 

代码如下:

import java.util.*;

//Problem 1000
public class Main
{
    public static void main(String args[])
    {
        Scanner cin = new Scanner(System.in);
        int a = cin.nextInt();
        int b = cin.nextInt();
        System.out.println(a + b);
    }
}

 

内存:1972K

运行时间:672MS

 

你可能感兴趣的:(ACM)