HOJ 1002 A+B+C

来源:互联网 发布:windows xp 安装盘 编辑:程序博客网 时间:2024/05/17 03:28
Time limit : 3 sec Memory limit : 32 M


For each pair of integers A B and C ( -2^31 <= A, B, C<= 2^31-1 ), Output the result of A+B+C on a single line.

Sample Input
1 2 33 4 3
Sample Output
610
提示 请注意32位机上int的表示范围。

Solution:
#include <stdio.h>int main(){    long long int a,b,c;    while(scanf("%lld %lld %lld",&a,&b,&c) == 3)    {        printf("%lld\n", a+b+c);    }    return 0;}


原创粉丝点击