问题描述
Given two integers A and B, your task is to output their sum, A+B.
输入格式
The input contains of only one line, consisting of two integers A and B. (0 ≤ A,B ≤ 1 000)
输出格式
The output should contain only one number that is A+B.
样例输入
1 1
样例输出
2
#include<iostream>
using namespace std;
int main()
{
int A, B;
cin >> A >> B;
cout << A+B << endl;
return 0;
}

本文介绍了一个简单的C++程序,用于接收两个整数输入并输出它们的和。程序使用标准输入输出流,适用于初学者理解基本的C++语法和流程控制。
4692

被折叠的 条评论
为什么被折叠?



