submission_id
string
problem_id
string
status
string
code
string
input
string
output
string
problem_description
string
s754618818
p00002
Wrong Answer
import sys import math for line in sys.stdin: a, b = map(int, line.split()) print(int(math.log(a + b, 10)//1 + 1))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s125275083
p00002
Wrong Answer
import sys import math for line in sys.stdin: a, b = map(int, line.split()) print(int(math.log(a + b, 10) + 1))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s118282581
p00002
Wrong Answer
import math def main(): data = [] while 1: try: n = input().split() a = int(n[0]) b = int(n[1]) ans = int(math.log10(a+b)+1) data.append(ans) except EOFError: break except IndexError: break for i in data: print(i)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s740739531
p00002
Wrong Answer
def main(): for i in range(3): A = list(map(int,input().split())) C = A[0]+A[1] count = 0 while True: C/=10 if C < 1: break count += 1 print(count+1) if __name__ == '__main__': main()
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s958277218
p00002
Wrong Answer
a = raw_input() ;l = a.split(); print(len(str(l[0]))) if (len(l) != 2) else len(str(int(l[0])+ int(l[1])))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s158749187
p00002
Wrong Answer
a = raw_input() ;l = a.split(); print(len(str(l[0]))) if (len(l) != 2) else (len(str((int(l[0]) + int(l[1]))))) if(int(l[0]) + int(l[1]) > 0) else (len(str((int(l[0]) + int(l[1])))) - 1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s718368057
p00002
Wrong Answer
a,b=map(int,input().split()) c=a+b ans=0 if c>=0 and c<=9: ans=1 if c>=10 and c<=99: ans=2 if c>=100 and c<=999: ans=3 if c>=1000 and c<=9999: ans=4 if c>=10000 and c<=99999: ans=5 if c>=100000 and c<=999999: ans =6 if c>=1000000 and c<=9999999: ans=7 print(ans)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s249429330
p00002
Wrong Answer
a,b=map(int,input().split()) c=a+b ans=0 if c>=0 and c<=9: ans=1 if c>=10 and c<=99: ans=2 if c>=100 and c<=999: ans=3 if c>=1000 and c<=9999: ans=4 if c>=10000 and c<=99999: ans=5 if c>=100000 and c<=999999: ans =6 if c>=1000000 and c<=9999999: ans=7 print(str(ans))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s624990066
p00002
Wrong Answer
while True: try:a,b=map(int,input().split()) except:break c=a+b ans=0 while c>=9: c=c//10 ans+=1 ans+=1 print(ans)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s862701564
p00002
Wrong Answer
while True: try: a = int(input()) b = int(input()) print(len(str(a + b))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s922887280
p00002
Wrong Answer
import math a, b = map(int, input().split()) ans = a + b print(int(math.log10(ans)) + 1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s883293754
p00002
Wrong Answer
import math a, b = map(int, input().split()) print(int(math.log10(a + b)) + 1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s568705585
p00002
Wrong Answer
import math a,b=map(int,input().split()) print(int(math.log10(a+b))+1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s295347413
p00002
Wrong Answer
import math a,b = [int(x) for x in input().split()] x = a + b print(int(math.log10(x))+1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s803235381
p00002
Wrong Answer
#!/usr/bin/env python3 import collections import sys def read_prob(): inputs = [] try: while True: line = input().strip().split() a, b = line[0], line[1] inputs.append(int(a) + int(b)) except EOFError: pass return inputs if __name__ == '__main__': inputs = read_prob() for i in range(3): answer = len(str(inputs[i])) print(answer)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s712747620
p00002
Wrong Answer
#!/usr/bin/env python3 import collections import sys def read_prob(): inputs = [] try: while True: line = input().strip().split(" ") a, b = line[0], line[1] inputs.append(int(a) + int(b)) except EOFError: pass return inputs if __name__ == '__main__': inputs = read_prob() for i in range(3): answer = len(str(inputs[i])) print(answer)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s072505367
p00002
Wrong Answer
a, b = input().split() n = a + b num = int(n) count = 0 while num: i = num % 10 num = num // 10 if i is 0: continue else: count += 1 print(count)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s547221762
p00002
Wrong Answer
a,b = map(int, input().split()) sum = a + b digits = 1 while(sum//10 != 0): digits += 1 sum //= 10 print(str(digits))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s711061681
p00002
Wrong Answer
import sys a = [] for line in sys.stdin: a.append(line) for i in a: print(i[0] + i[1])
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s282634808
p00002
Wrong Answer
import sys a = [] for line in sys.stdin: a.append(line) for i in a: sum = i[0] + i[1] print(len(str(sum)))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s052310994
p00002
Wrong Answer
def main(): while True: try: a, b = (int(x) for x in input().split()) print(len(str(a+b))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s186676365
p00002
Wrong Answer
a, b = (int(x) for x in input().split()) print(len(str(a+b)))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s185479601
p00002
Wrong Answer
while True: try: a, b = (int(x) for x in input().split()) print(a + b) except: break;
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s017846001
p00002
Wrong Answer
import sys, math def run(): N = [] for n in sys.stdin: a,b = map(int, n.split()) N.append((a,b)) for a,b in N: print(math.ceil(math.log10(a+b))) if __name__ == '__main__': run()
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s337585816
p00002
Wrong Answer
a,b = map(int,raw_input().split()) d = 0 c = a+b while c > 1: c /= 10 d += 1 print d
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s074770111
p00002
Wrong Answer
while True: if EOFError: break else: x = map(int, raw_input().split(" ")) print len(str(x[0]+x[1]))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s077384775
p00002
Wrong Answer
#condig: UTF-8 n = map(int, raw_input().split()) s = len(str(n[0] + n[1])) print s
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s355538603
p00002
Wrong Answer
n = map(int, raw_input().split()) s = len(str(n[0] + n[1])) print s
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s259343342
p00002
Wrong Answer
while 1: try: a,b = raw_input().split() n = a+b print len(str(n)) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s643097123
p00002
Wrong Answer
#!/usr/bin/env python # coding: utf-8 def main(): inputs = [] while 1: try: inputs.append(raw_input()) except EOFError: break for line in inputs: print (lambda a, b: len(str(a + b)))(*line.split(" ")) if __name__ == '__main__': main()
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s378235514
p00002
Wrong Answer
while True: try: a, b = [int(i) for i in raw_input().split()] print a + b except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s650045174
p00002
Wrong Answer
x=raw_input() a=int(x[0]) b=int(x[2]) def digit_num(a): def digit_num_sub(a,n): if a/(10**n)<10: return n+1 else: return digit_num_sub(a,n+1) return digit_num_sub(a,0) print digit_num(a+b)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s733682286
p00002
Wrong Answer
while True: try: a, b = raw_input().strip().split(" "); print len(str(a + b)) except: break;
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s704036688
p00002
Wrong Answer
x = map(int,raw_input().split(' ')) a = x[0]+x[1] if 0<=a<10: print 1 elif 10<=a<100: print 2 elif 100<=a<1000: print 3 elif 1000<=a<10000: print 4 elif 10000<=a<100000: print 5 elif 100000<=a<1000000: print 6 else: print 7
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s700382357
p00002
Wrong Answer
x = map(int,raw_input().split(' ')) a = x[0]+x[1] if 0<a<10: print 1 elif 9<a<100: print 2 elif 99<a<1000: print 3 elif 999<a<10000: print 4 elif 9999<a<100000: print 5 elif 99999<a<1000000: print 6 else: print 7
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s694163907
p00002
Wrong Answer
import math x = map(int,raw_input().split(' ')) a = math.log10(x[0] + x[1]) print(int(a)+1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s329395076
p00002
Wrong Answer
import math x = map(int,raw_input().split(' ')) a = math.log10(x[0] + x[1]) print(int(a)+int(1))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s749513781
p00002
Wrong Answer
import sys for line in sys.stdin: print(sum(map(int,line.split())))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s792615172
p00002
Wrong Answer
print len(str(sum(map(int,raw_input().split()))))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s453587893
p00002
Wrong Answer
data = ["5 7", "1 99", "1000 999"] for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b: print 6 elif 10000 <= a + b: print 5 elif 1000 <= a + b: print 4 elif 100 <= a + b: print 3 elif 10 <= a + b: print 2 elif 0 <= a + b: print 1
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s259617218
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except EOFError: pass print data for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b: print 6 elif 10000 <= a + b: print 5 elif 1000 <= a + b: print 4 elif 100 <= a + b: print 3 elif 10 <= a + b: print 2 elif 0 <= a + b: print 1
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s910016264
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except (EOFError): pass print data for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b: print 6 elif 10000 <= a + b: print 5 elif 1000 <= a + b: print 4 elif 100 <= a + b: print 3 elif 10 <= a + b: print 2 elif 0 <= a + b: print 1
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s628420731
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except (EOFError): pass print data for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b: print 6 if 10000 <= a + b: print 5 if 1000 <= a + b: print 4 if 100 <= a + b: print 3 if 10 <= a + b: print 2 if 0 <= a + b: print 1
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s150859534
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except EOFError: pass for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b: print 6 elif 10000 <= a + b: print 5 elif 1000 <= a + b: print 4 elif 100 <= a + b: print 3 elif 10 <= a + b: print 2 elif 0 <= a + b: print 1
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s889490546
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except EOFError: pass ans = [] for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b: ans.append(6) elif 10000 <= a + b: ans.append(5) elif 1000 <= a + b: ans.append(4) elif 100 <= a + b: ans.append(3) elif 10 <= a + b: ans.append(2) elif 0 <= a + b: ans.append(1) for i in ans: print i
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s669166198
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except EOFError: pass ans = [] for i in data: x, y = i.split() a, b = int(x), int(y) if 100000 <= a + b <= 1000000: ans.append(6) elif 10000 <= a + b: ans.append(5) elif 1000 <= a + b: ans.append(4) elif 100 <= a + b: ans.append(3) elif 10 <= a + b: ans.append(2) elif 0 <= a + b: ans.append(1) for i in ans: print i
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s941583010
p00002
Wrong Answer
try: data = [] while True: data.append(raw_input()) except EOFError: pass for i in data: x, y = i.split() a, b = int(x), int(y) for j in range(1, 7): if (a + b) / (10 ** j) < 1: print j break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s982197292
p00002
Wrong Answer
list = raw_input().split() print len(str(int(list[0])+int(list[1])))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s635721880
p00002
Wrong Answer
list = raw_input().split() print len(str(eval(list[0])+eval(list[1])))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s701926831
p00002
Wrong Answer
import sys import math for line in sys.stdin: a, b = map(int, line.split(' ')) print(math.log10(a + b) + 1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s989347245
p00002
Wrong Answer
# -*- utf-8 -*- i = raw_input() a = int(i.split(" ")[0]) b = int(i.split(" ")[1]) s = a + b ans = 0 while(s >= 1): s /= 10 ans += 1 print ans
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s325120618
p00002
Wrong Answer
try: a, b = map(int,raw_input().split()) print len(str(a+b)) except: pass
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s545523016
p00002
Wrong Answer
import sys for line in sys.stdin: l = map(lambda i:int(i), line.split(' ')) print l[0] + l[1]
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s650766717
p00002
Wrong Answer
#!/usr/bin/env python dn = lambda a, b: len(str(a+b)) get = lambda : [int (x) for x in raw_input().split()] if __name__ == "__main__": print "%d\n" % dn(*get()),
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s716428291
p00002
Wrong Answer
a, b = map(int, raw_input().split()) print(len(list(str(a + b))))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s429531519
p00002
Wrong Answer
[a, b] = map(int, raw_input().split(" ")) n = a+b ans = 1 while(n >= 10): n /= 10 ans += 1 print ans
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s516770479
p00002
Wrong Answer
import sys try: a,b=map(int,raw_input().split()) print a+b except: sys.exit()
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s534423661
p00002
Wrong Answer
import sys while 1: try: a,b=map(int,raw_input().split()) print a+b except: sys.exit()
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s685835603
p00002
Wrong Answer
import sys for jk in sys.stdin: j,k=map(int,jk.split()) print j+k
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s375586050
p00002
Wrong Answer
a = raw_input().split() ans = 0 i = 0 for i in range(len(a)): a[i] = int(a[i]) while a[i] >= 1: a[i] = a[i]/10 ans += 1 print ans
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s953158757
p00002
Wrong Answer
a = raw_input().split() ans = 0 for i in range(len(a)): a[i] = int(a[i]) while a[i] >= 1: a[i] = a[i]/10 ans += 1 print ans
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s232469299
p00002
Wrong Answer
a,b=map(int,raw_input().split()) c = str(a+b) print len(c)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s757320812
p00002
Wrong Answer
while True: try: a,b = map(int,input().split(" ")) print(a+b) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s750429671
p00002
Wrong Answer
while True: try: line = input() except: break a, b = map(int, input().strip().split()) print(len(str(a + b)))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s535071788
p00002
Wrong Answer
(m,n) = map(int,raw_input().split()) print m + n
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s596317011
p00002
Wrong Answer
import math while True: try: a, b = map(int, raw_input().split()) except EOFError: break print(int(math.log10(a + b)) + 1)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s969548113
p00002
Wrong Answer
while True: try: a, b = map(int, raw_input().split()) print a + b except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s289503395
p00002
Wrong Answer
print "\n".join(["%dx%d=%d" % (i/10+1,i%10,((i/10)+1)*(i%10)) for i in range(1,99) if i%10!=0])
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s150571965
p00002
Wrong Answer
print "\n".join(["%dx%d=%d" % (i/10,i%10,(i/10)*(i%10)) for i in range(10,100) if i%10!=0])
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s481100566
p00002
Time Limit Exceeded
while 1: try: list = str(raw_input()).split() x = int(list[0]) + int(list[1]) print "%d" % len(str(x)) except: print"hoge"
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s335048862
p00002
Time Limit Exceeded
while True: inNums = input().strip().split() a = int(inNums[0]) b = int(inNums[1]) temp = a+b x = 0 digitNum = 0 while temp // 10**x > 0: digitNum = x print(x) if inNums == None: break break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s776363022
p00002
Time Limit Exceeded
def plus_and_check(list): sum_up = 0 for i in range(len(list)-1): sum_up += list[i] i = 0 while i < 8: number_1 = 10 * i number_2 = 10 * (i+1) if number_2 > sum_up and number_1 < sum_up: return i else: continue i = i + 1 l = map(int, raw_input().split()) print "%d" % plus_and_check(l)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s075717311
p00002
Time Limit Exceeded
def plus_and_check(list): sum_up = 0 for i in range(len(list)-1): sum_up += list[i] i = 0 while i < 8: number_1 = 10 * i number_2 = 10 * (i+1) if number_2 > sum_up and number_1 < sum_up: break else: continue i = i + 1 return i l = map(int, raw_input().split()) print "%d" % plus_and_check(l)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s808463439
p00002
Time Limit Exceeded
def plus_and_check(list): sum_up = sum(list) i = 0 while i < 8: number_1 = 10 * i number_2 = 10 * (i+1) if number_2 > sum_up and number_1 < sum_up: break else: continue i = i + 1 return i l = map(int, raw_input().split()) print "%d" % plus_and_check(l)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s344821228
p00002
Time Limit Exceeded
import math lst = [] while True: try: a, b = map(int, input().split()) lst.append(int(math.log(10, a+b))+1) except EOFError: for i in lst: print(i)
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s468018150
p00002
Time Limit Exceeded
x = map(int,raw_input().split(' ')) a = x[0]+x[1] b = 1 c = 10**b while True: if a/c != 0: b += 1 continue else: break print b
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s147875329
p00002
Time Limit Exceeded
a = raw_input().split() ans = 0 for i in range(len(a)): a[i] = int(a[i]) while a[i] < 1: a[i] = a[i]/10 ans += 1 print ans
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s003454110
p00002
Accepted
while True: try:print(len(str(sum(map(int,input().split()))))) except:break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s611080249
p00002
Accepted
try: while True: print len(str(sum(map(int, raw_input().split())))) except: pass
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s296313644
p00002
Accepted
while True: try: a,b = map(int,input().split(" ")) print(len(str(a+b))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s038607024
p00002
Accepted
while True: try: a, b = map(int, input().split(" ")) print(len(str(a + b))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s807722522
p00002
Accepted
while True: try: a, b = map(int, input().split(" ")) print(len(str(a + b))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s391618214
p00002
Accepted
while True: try: a,b=[int(i) for i in input().split()] print(len(str(a+b))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s811134390
p00002
Accepted
while True: try: a, b = map(int, input().split()) print(len(str(a + b))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s051608418
p00002
Accepted
while True: try: a,b = list(map(int,input().split())) print(len(str(a+b))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s927357381
p00002
Accepted
while True: try: a,b = list(map(int,input().split())) print(len(str(a+b))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s716305968
p00002
Accepted
while 1: try: a,b = input().split() a = int(a) b = int(b) c = a + b print(len(str(c))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s700614061
p00002
Accepted
while 1: try: sum = input() sum_list = sum.split() print(len(str(int(sum_list[0]) + int(sum_list[1])))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s451115619
p00002
Accepted
def calculate_digit_num(num): z = num / 10 if z == 0: return 1 else: return 1 + calculate_digit_num(z) while True: try: num_list = [int(num) for num in raw_input().split(' ')] print calculate_digit_num(sum(num_list)) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s146804308
p00002
Accepted
# -*- coding: utf-8 -*- import sys for s in sys.stdin: print len(str(int(s.rstrip().split()[0])+int(s.rstrip().split()[1])))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s553598962
p00002
Accepted
while True: try: a,b=map(int,input().split()) print(len(str(a+b))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s395955333
p00002
Accepted
while True: try: print(len(str(sum(list(map(int, input().split())))))) except: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s810966501
p00002
Accepted
while True: try: a, b = map(int, input().split()) print(len(str(a+b))) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s537331495
p00002
Accepted
try: while True: print(len(str(sum(map(int, input().split()))))) except: pass
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s374124427
p00002
Accepted
import sys for i in sys.stdin: a, b = map(int, i.split()) print len(str(a+b))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s361032758
p00002
Accepted
import sys #list = sys.stdin.readlines() #i=0 list = [] for line in sys.stdin.readlines(): list = line.split(" ") print str(len(str(int(list[0]) + int(list[1]))))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s823447365
p00002
Accepted
while(True): try: a = map(int, raw_input().split()) b = str(a[0] + a[1]) print(len(b)) except Exception: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s172779060
p00002
Accepted
while True: try: [a, b] = map(int, raw_input().split()) sum = a + b count = 0 while sum: count += 1 sum /= 10 print count except (EOFError): break;
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s615612002
p00002
Accepted
import sys for s in sys.stdin:print len(str(sum(map(int,s.split()))))
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>
s207857033
p00002
Accepted
def digits(x): i=0 while (x>0): x/=10 i+=1 return i while True: try: line=raw_input() (a,b)=line.split() (a,b)=map(int,(a,b)) print digits(a+b) except EOFError: break
5 7 1 99 1000 999
2 3 4
<H1>Digit Number</H1> <p> Write a program which computes the digit number of sum of two integers <var>a</var> and <var>b</var>. </p> <H2>Input</H2> <p> There are several test cases. Each test case consists of two non-negative integers <var>a</var> and <i>b</i> which are separeted by a space in a line. The input terminates with EOF. </p> <h2>Constraints</h2> <ul> <li>0 &le; <var>a</var>, <var>b</var> &le; 1,000,000</li> <li>The number of datasets &le; 200</li> </ul> <H2>Output</H2> <p> Print the number of digits of <var>a</var> + <var>b</var> for each data set. </p> <H2>Sample Input</H2> <pre> 5 7 1 99 1000 999 </pre> <H2>Output for the Sample Input</H2> <pre> 2 3 4 </pre>