BZOJ 1000: A+B Problem
2014-02-19 12:09
253 查看
题目地址:http://www.lydsy.com/JudgeOnline/problem.php?id=1000
题目大意:输入a,b,输出a+b。
算法讨论:
作为BZOJ的第一题,目的是让大家了解BZOJ的输入输出方式。
由此题可以发现BZOJ的输入输出方式是标准输入输出(即不用文件输入输出)。
Code:
Update:前几天看了“短码编程”,发现此题其实可以写的很短。
Code:main(a,b){scanf("%d%d",&a,&b);printf("%d\n",a+b);}
当然前提是用GCC的编译器~
By Charlie Pan
Feb 19,2014
题目大意:输入a,b,输出a+b。
算法讨论:
作为BZOJ的第一题,目的是让大家了解BZOJ的输入输出方式。
由此题可以发现BZOJ的输入输出方式是标准输入输出(即不用文件输入输出)。
Code:
/* * Problem:1000 * Author:PYC */ #include <cstdio> using namespace std; int main(){ int a,b; scanf("%d%d",&a,&b); printf("%d\n",a+b); return 0; }
Update:前几天看了“短码编程”,发现此题其实可以写的很短。
Code:main(a,b){scanf("%d%d",&a,&b);printf("%d\n",a+b);}
当然前提是用GCC的编译器~
By Charlie Pan
Feb 19,2014
相关文章推荐
- bzoj 1000: A+B Problem
- BZOJ 1000 A+B Problem (I/O)
- 【BZOJ1000】A+B Problem
- BZOJ-1000 A + B Problem 丧心病狂
- [bzoj1000] A+B Problem
- 【BZOJ1000】【POJ1000】【HDU1000】【Vijos P1000】A+B Problem
- bzoj1000 A+B Problem
- BZOJ 1000 A+B Problem
- BZOJ 1000: A+B Problem
- BZOJ 1000: A+B Problem
- 【BZOJ1000】A+B Problem ★BZOJ1000题达成★
- bzoj1000 A+B Problem
- BZOJ1000[A+B Problem]题解--基础题
- POJ 1000 A+B Problem
- Problem-1000:A + B Problem
- bzoj3489 A simple rmq problem
- [bzoj 3339&bzoj 3585]Rmq Problem&mex
- [BZOJ2301][HAOI2011]Problem b(莫比乌斯反演)
- [BZOJ]4999: This Problem Is Too Simple! 树链剖分
- 【bzoj4999】This Problem Is Too Simple! 树链剖分+动态开点线段树