Submission #00164


ソースコード

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#include<iostream>
using namespace std;
int main(){
long long a[1000];
long long b[1000];
int i=0;
long long sum;
long long ans;
int x=0;
while(1){
cin>>a[i]>>b[i];
if(a[i]>=((long long)9223372036854775807)/2&&b[i]>=((long long)9223372036854775807)/2){
sum=a[i]/10;
sum*=10;
ans=a[i]-sum;
sum=b[i]/10;
sum*=10;
ans=b[i]-sum;
if(sum+ans>=10){
x=sum+ans;
x-=10;
cout<<a[i]+b[i]+1<<x<<endl;
return(0);
}
if(a[i]==0&&b[i]==0){
break;
}
i++;
}
for(int j=0;j<i;j++){
cout<<a[j]+b[j]<<sum<<endl;
}
}
return(0);
}

ステータス

項目 データ
問題 0002 - 算数(足し算)2
ユーザー名 conflict
投稿日時 2017-08-08 11:44:07
言語 C++
状態 Time Limit Exceeded
得点 0
ソースコード長 590 Byte
最大実行時間 1000 ms
最大メモリ使用量 700 KB

セット

セット 得点 Cases
1 ALL 0 / 20 *

テストケース

ファイル名 状態 実行時間 メモリ使用量 #
input1.txt TLE 1000 ms 480 KB
1
input2.txt TLE 1000 ms 536 KB
1
input3.txt TLE 1000 ms 600 KB
1
input4.txt TLE 1000 ms 700 KB
1
input5.txt TLE 1000 ms 548 KB
1
input6.txt TLE 1000 ms 520 KB
1
input7.txt TLE 1000 ms 616 KB
1
input8.txt TLE 1000 ms 588 KB
1
input9.txt TLE 1000 ms 564 KB
1
input10.txt TLE 1000 ms 452 KB
1
input11.txt WA 14 ms 552 KB
1
input12.txt WA 11 ms 520 KB
1
input13.txt WA 11 ms 492 KB
1
input14.txt WA 14 ms 592 KB
1
input15.txt WA 11 ms 560 KB
1
input16.txt WA 12 ms 524 KB
1
input17.txt WA 13 ms 492 KB
1
input18.txt WA 15 ms 464 KB
1
input19.txt WA 13 ms 436 KB
1
input20.txt WA 13 ms 636 KB
1