s_id string | p_id string | u_id string | date string | language string | original_language string | filename_ext string | status string | cpu_time string | memory string | code_size string | code string | error string | stdout string |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
s563031671 | p03998 | u785578220 | 1551933797 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 290 | a = input()
b = input()
c = input()
l = list(a)
m = list(b)
n = list(c)
if len(l)>0:
t = a.pop()
k = 'a'
while len(l) >0 and len(m) > 0 and len(n) > 0:
k = t
if t == 'a':
t = l.pop()
elif t == 'b':
t = m.pop()
elif t == 'c':
t = n.pop()
print(k) | Traceback (most recent call last):
File "/tmp/tmpct4n2orp/tmp39oi9eum.py", line 1, in <module>
a = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s564981296 | p03998 | u785578220 | 1551933695 | Python | Python (3.4.3) | py | Runtime Error | 22 | 3060 | 258 | a = input()
b = input()
c = input()
l = []
m = []
n = []
t = a.pop()
k = 'a'
while len(l) >0 and len(m) > 0 and len(n) > 0:
k = t
if t == 'a':
t = a.pop()
elif t == 'b':
t = b.pop()
elif t == 'c':
t = c.pop()
print(k) | Traceback (most recent call last):
File "/tmp/tmpaulhn0zd/tmplk_1wsdw.py", line 1, in <module>
a = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s372326482 | p03998 | u118211443 | 1551742376 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 438 | a=list(input())
b=list(input())
c=list(input())
read=a[0]
a.pop(0)
while(1):
if read=='a':
if len(a)==0:
break
read=a[0]
f='A'
a.pop(0)
elif read=='b':
if len(b)==0:
break
read=b[0]
f='B'
b.pop(0)
elif read=='c':
if len(c)==0:
break
read=c[0]
f='C'
c.pop(0)
print(f) | Traceback (most recent call last):
File "/tmp/tmpg7ufnxfm/tmpemcwae6n.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s708921585 | p03998 | u033524082 | 1551230708 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 330 | l=[]
for i in range(3):
l.append(input())
turn=0
next_turn=0
while True:
s=l[turn][0]
l[turn]=l[turn][1:]
if s=="a":
turn=0
elif s=="b":
turn=1
else:
turn=2
if l[0]=="":
print("A")
break
elif l[1]=="":
print("B")
elif l[2]=="":
print("C") | Traceback (most recent call last):
File "/tmp/tmpjsbnjpcw/tmpts0oflho.py", line 3, in <module>
l.append(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s950057510 | p03998 | u952130512 | 1550492301 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 303 | A=input()
B=input()
C=input()
s="a"
while (len(A)!=0 or s!="a") and (len(B)!=0 or s!="b") and (len(C)!=0 or s!="c"):
if s=="a":
s=A[0]
A=A[1:]
elif s=="b":
s=B[0]
B=B[1:]
else:
s=C[0]
C=C[1:]
if len(a)==0:
print("A")
elif len(b)==0:
print("B")
else:
print("C")
| Traceback (most recent call last):
File "/tmp/tmpqbzsx4c9/tmplhvtz0y1.py", line 1, in <module>
A=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s984320263 | p03998 | u952130512 | 1550492249 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 303 | A=input()
B=input()
C=input()
s="a"
while (len(a)!=0 or s!="a") and (len(b)!=0 or s!="b") and (len(c)!=0 or s!="c"):
if s=="a":
s=A[0]
A=A[1:]
elif s=="b":
s=B[0]
B=B[1:]
else:
s=C[0]
C=C[1:]
if len(a)==0:
print("A")
elif len(b)==0:
print("B")
else:
print("C")
| Traceback (most recent call last):
File "/tmp/tmpxg2zg3dm/tmpyl1zxc20.py", line 1, in <module>
A=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s751518124 | p03998 | u952130512 | 1550492206 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 305 | A=input()
B=input()
C=input()
s="a"
while (len(a)!=0 or s!="a") and (len(b)!=0 or s!="b") and (len(c)!=0 or s!="c"):
if s=="a":
s=A[0]
A=A[1:]
elif s=="b":
s=B[0]
B=B[1:]
else:
s=C[0]
C=C[1:]
if len(s1)==0:
print("A")
elif len(s2)==0:
print("B")
else:
print("C")
| Traceback (most recent call last):
File "/tmp/tmpx9u0mxgj/tmpk33rubnl.py", line 1, in <module>
A=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s254043686 | p03998 | u952130512 | 1550491493 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 351 | A=input()
B=input()
C=input()
s="a"
while true:
print(str(len(A))+str(len(B))+str(len(C)))
if s=="a":
s=A[0]
A=A[1:]
if len(A)==0:
print("A")
break
elif s=="b":
s=B[0]
B=B[1:]
if len(B)==0:
print("B")
break
else:
s=C[0]
C=C[1:]
if len(C)==0:
print("C")
break
| Traceback (most recent call last):
File "/tmp/tmpou9jhfvw/tmp7ccsegev.py", line 1, in <module>
A=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s319994632 | p03998 | u952130512 | 1550491460 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 346 | A=input()
B=input()
C=input()
s="a"
while:
print(str(len(A))+str(len(B))+str(len(C)))
if s=="a":
s=A[0]
A=A[1:]
if len(A)==0:
print("A")
break
elif s=="b":
s=B[0]
B=B[1:]
if len(B)==0:
print("B")
break
else:
s=C[0]
C=C[1:]
if len(C)==0:
print("C")
break
| File "/tmp/tmp482ocqnk/tmpykzulyv7.py", line 5
while:
^
SyntaxError: invalid syntax
| |
s596019103 | p03998 | u952130512 | 1550489077 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 459 | A=input()
B=input()
C=input()
s=a
while len(A)!=0 and len(B)!=0 and len(C)!=0:
if s=="a":
if A[0]=="b":
s="b"
continue
if A[0]=="c":
s="c"
continue
elif s=="b":
if B[0]=="c":
s="c"
continue
if B[0]=="a":
s="a"
continue
else:
if C[0]=="a":
s="a"
continue
if C[0]=="b":
s="b"
continue
if len(A)==0:
print("A")
elif len(B)==0:
print("B")
else:
print("C") | Traceback (most recent call last):
File "/tmp/tmp69562q8k/tmpr1l30x92.py", line 1, in <module>
A=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s892738419 | p03998 | u952130512 | 1550489015 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 439 | A=input()
B=input()
C=input()
s=a
while len(A)!=0 and len(B)!=0 and len(C)!=0:
if s==a:
if A[0]==b:
s=b
continue
if A[0]==c:
s=c
continue
elif s==b:
if B[0]==c:
s=c
continue
if B[0]==a:
s=a
continue
else:
if C[0]==a:
s=a
continue
if C[0]==b:
s=b
continue
if len(A)==0:
print("A")
elif len(B)==0:
print("B")
else:
print("C")
| Traceback (most recent call last):
File "/tmp/tmpqhyjx9_i/tmp2135v2yq.py", line 1, in <module>
A=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s016261358 | p03998 | u518064858 | 1550388858 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 433 | s1=input()
s2=input()
s3=input()
x=s1[0]
s1.lstrip(x)
y=1
while y>0:
if x=="a":
x=s1[0]
s1=s1[1:]
if x=="a" and len(s1)==0:
print("A")
y=0
elif x=="b":
x=s2[0]
s2=s2[1:]
if x=="b" and len(s2)==0:
print("B")
y=0
else:
x=s3[0]
s3=s3[1:]
if x=="c" and len(s3)==0:
print("C")
y=0
| Traceback (most recent call last):
File "/tmp/tmpmu32fiaq/tmp2iey4dff.py", line 1, in <module>
s1=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s251693756 | p03998 | u518064858 | 1550388712 | Python | Python (3.4.3) | py | Runtime Error | 19 | 3064 | 442 | s1=input()
s2=input()
s3=input()
x=s1[0]
s1.lstrip(x)
y=1
while y>0:
if x=="a":
x=s1[0]
s1=s1[1:]
if x=="a" and len(s1)==0:
print("A")
exit()
elif x=="b":
x=s2[0]
s2=s2[1:]
if x=="b" and len(s2)==0:
print("B")
exit()
else:
x=s3[0]
s3=s3[1:]
if x=="c" and len(s3)==0:
print("C")
exit()
| Traceback (most recent call last):
File "/tmp/tmpcycx0xpt/tmpm5_2vtgx.py", line 1, in <module>
s1=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s011554830 | p03998 | u411858517 | 1550338397 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 486 | A = input()
B = input()
C = input()
now = A [0]
a = 1
b = 0
c = 0
while True:
if now == 'a':
if a + 1 == len(A):
res = 'A'
break
now = A[a+1]
a = a + 1
if now == 'b':
if b + 1 == len(B):
res = 'B'
break
now = B[b+1]
b = b + 1
if now == 'c':
if c + 1 == len(C):
res = 'C'
break
now = C[c+1]
c = c + 1
print(res) | Traceback (most recent call last):
File "/tmp/tmpo1bmn5zi/tmpl3labbxq.py", line 1, in <module>
A = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s348096437 | p03998 | u483645888 | 1550255375 | Python | Python (3.4.3) | py | Runtime Error | 77 | 4064 | 600 | A = input()
B = input()
C = input()
flag = 'A'
def chk(A, B, C, flag, st):
if len(st) == 0:
return flag
elif st[0].upper() == flag:
if flag == 'A':
A = st[1:]
st = A
elif flag == 'B':
B = st[1:]
st = B
elif flag == 'C':
C = st[1:]
st = C
elif st[0] == 'a':
flag = 'A'
st = A[1:]
elif st[0] == 'b':
flag = 'B'
st = B[1:]
elif st[0] == 'c':
flag = 'C'
st = C[1:]
return chk(A, B, C, flag, st)
print(chk(A, B, C, flag, st=A)) | Traceback (most recent call last):
File "/tmp/tmp282n52rk/tmp90d_4ujy.py", line 1, in <module>
A = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s362030738 | p03998 | u231647664 | 1547418419 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 92 | S = {x: list(input()) for x in 'abc'}
s = 'a'
while S[s]:
s = S[s].pop(0)
print(upper(s))
| Traceback (most recent call last):
File "/tmp/tmpgucju25v/tmpsf97jcu_.py", line 1, in <module>
S = {x: list(input()) for x in 'abc'}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpgucju25v/tmpsf97jcu_.py", line 1, in <dictcomp>
S = {x: list(input()) for x in 'abc'}
^^^^^^^
EOFError: EOF when reading a line
| |
s299647701 | p03998 | u620945921 | 1546701480 | Python | Python (3.4.3) | py | Runtime Error | 19 | 3064 | 538 | a=list(input())
b=list(input())
c=list(input())
#print(a,b,c)
card=a.pop(0)
#print(card)
flag=0
for i in range(len(a)+len(b)+len(c)):
if card=='a' and len(a)==0 and flag==0:
ans='A'
flag=1
elif card=='b' and len(b)==0 and flag==0:
ans='B'
flag=1
elif card=='c' and len(c)==0 and flag==0:
ans='C'
flag=1
else:
if card=='a':
card=a.pop(0)
elif card=='b':
card=b.pop(0)
elif card=='c':
card=c.pop(0)
print(ans) | Traceback (most recent call last):
File "/tmp/tmphj0yudya/tmpy0vj4ra4.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s877996322 | p03998 | u620945921 | 1546698856 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3188 | 829 | a=input()
b=input()
c=input()
sizea=len(a)
sizeb=len(b)
sizec=len(c)
print(sizea,sizeb,sizec)
flag=1
x=0
y=0
z=0
for i in range(301):
if flag==1:
if sizea==0:
ans='A'
break
else:
if a[x]=='a':
flag=1
elif a[x]=='b':
flag=2
elif a[x]=='c':
flag=3
sizea-=1
x+=1
print(sizea,a[x])
elif flag==2:
if sizeb==0:
ans='B'
break
else:
if b[y]=='a':
flag=1
elif b[y]=='b':
flag=2
elif b[y]=='c':
flag=3
sizeb-=1
y+=1
print(sizeb,b[y])
elif flag==3:
if sizec==0:
ans='C'
break
else:
if c[z]=='a':
flag=1
elif c[z]=='b':
flag=2
elif c[z]=='c':
flag=3
sizec-=1
z+=1
print(sizec,c[z])
print(ans) | Traceback (most recent call last):
File "/tmp/tmp_w8i0j6n/tmpdka7z9ks.py", line 1, in <module>
a=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s941466118 | p03998 | u620945921 | 1546643690 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 470 | a=input()
b=input()
c=input()
cnta=len(a)
cntb=len(b)
cntc=len(c)
print(a,b,c)
print(cnta,cntb,cntc)
numa=0
numb=0
numc=0
flag=1
if flag==1:
numa+=1
elif flag==2:
numb+=1
elif flag==3:
numc+=1
if a[numa]=='a':
flag=1
elif a[numa]=='b':
flag=2
elif a[numa]=='c':
flag=3
if flag==1:
numa+=1
elif flag==2:
numb+=1
elif flag==3:
numc+=1
print(a[numa])
if a[numa]=='a':
flag=1
elif a[numa]=='b':
flag=2
elif a[numa]=='c':
flag=3
numa+=1
| Traceback (most recent call last):
File "/tmp/tmp0taqq3l9/tmpe8v4gwjp.py", line 1, in <module>
a=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s899674012 | p03998 | u371467115 | 1545800816 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 119 | s = {"a":input(), "b":input(), "c":input()}
x = "a"
while len(s[x])!=0:
i = s[x].pop[0]
x = i
print(x.upper())
| Traceback (most recent call last):
File "/tmp/tmpo7vri30v/tmp6rm5cckg.py", line 1, in <module>
s = {"a":input(), "b":input(), "c":input()}
^^^^^^^
EOFError: EOF when reading a line
| |
s683573292 | p03998 | u201234972 | 1544153981 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 273 | S = [list( input()) for _ in range(3)]
C = ['A', 'B', 'C']
now = 0
nowc = 'A'
while True:
if not S[i]:
ans = C[i]
break
nowc = S[i].pop(0)
if nowc == 'a':
now = 0
elif nowc == 'b':
now = 1
else:
now = 2
print(ans) | Traceback (most recent call last):
File "/tmp/tmpw3sbybd6/tmp74ie_v10.py", line 1, in <module>
S = [list( input()) for _ in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpw3sbybd6/tmp74ie_v10.py", line 1, in <listcomp>
S = [list( input()) for _ in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s384173175 | p03998 | u140251125 | 1543159972 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 338 | # input
S = [list(input()) for _ in range(3)]
P_curr = 0
while S[P_curr] != []
if S[P_curr][0] == 'a':
P_curr = 0
if S[P_curr][0] == 'b':
P_curr = 1
if S[P_curr][0] == 'c':
P_curr = 2
del S[P_curr][0]
if P_curr == 0:
print('A')
if P_curr == 1:
print('B')
if P_curr == 2:
print('C')
| File "/tmp/tmpcbvhj82k/tmp1u4cu_q0.py", line 6
while S[P_curr] != []
^
SyntaxError: expected ':'
| |
s320807825 | p03998 | u869728296 | 1542816697 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 126 | sa=input()
sb=input()
sc=input()
sa=list(sa)
sb=list(sb)
sc=list(sc)
for i in range(len(sa)+len(sb)+len(sc)):
if(sa[0])
| File "/tmp/tmpcs8rup7o/tmp730bv1i_.py", line 10
if(sa[0])
^
SyntaxError: expected ':'
| |
s598973082 | p03998 | u754553095 | 1541710835 | Python | Python (3.4.3) | py | Runtime Error | 24 | 3060 | 184 | a,b,c,=list(input()),list(input()),list(input())
d=a[0]
e=0
a.remove(d)
while True:
if eval(d)==[]:
break
e=eval(d)[0]
eval(d).remove(e)
d=e
print(str.upper(e)) | Traceback (most recent call last):
File "/tmp/tmpu99mnhay/tmp1zg1b7gy.py", line 1, in <module>
a,b,c,=list(input()),list(input()),list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s510090037 | p03998 | u637824361 | 1541121398 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 346 | S_A = [i for i in input()]
S_B = [i for i in input()]
S_C = [i for i in input()]
T = S_A
l = T.__len__()
while(l > 0):
if T.pop(0) == 'a':
T = S_A
elif T.pop(0) == 'b':
T = S_B
else:
T = S_C
l = T.__len__()
if 0 == S_A.__len__():
print("A")
elif 0 == S_B.__len__():
print("B")
else:
print("C")
| Traceback (most recent call last):
File "/tmp/tmpvcbhs5ds/tmpdfl3q7si.py", line 1, in <module>
S_A = [i for i in input()]
^^^^^^^
EOFError: EOF when reading a line
| |
s485113319 | p03998 | u090225501 | 1541111775 | Python | Python (3.4.3) | py | Runtime Error | 20 | 3316 | 162 | from collections import deque
m = [deque(input()) for _ in range(3)]
t = 0
while True:
n = m[t].popleft()
if not m[t]:
print('ABC'[t])
break
t = n | Traceback (most recent call last):
File "/tmp/tmpkdfqnah9/tmpz_i48cxd.py", line 3, in <module>
m = [deque(input()) for _ in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpkdfqnah9/tmpz_i48cxd.py", line 3, in <listcomp>
m = [deque(input()) for _ in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s773664452 | p03998 | u094191970 | 1539900773 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 638 | a, b, c = [int(input()) for i in range(3)]
a_list = list(a)
b_list = list(b)
c_list = list(c)
def decide_turn(list):
next_turn = list[0]
del list[0]
return next_turn
next_turn = decide_turn(a_list)
while 1 > 0:
if next_turn == a:
if a_list:
next_turn = decide_turn(a_list)
else:
print('A')
break
elif next_turn == b:
if b_list:
next_turn = decide_turn(b_list)
else:
print('B')
break
else:
if c_list:
next_turn = decide_turn(c_list)
else:
print('C')
break | Traceback (most recent call last):
File "/tmp/tmpk1vkaict/tmppe2475tm.py", line 1, in <module>
a, b, c = [int(input()) for i in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpk1vkaict/tmppe2475tm.py", line 1, in <listcomp>
a, b, c = [int(input()) for i in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s634508840 | p03998 | u595353654 | 1539749211 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 626 | # -*- coding: utf-8 -*-
from sys import stdin
stdin = open("sample.txt")
A = stdin.readline().rstrip()
B = stdin.readline().rstrip()
C = stdin.readline().rstrip()
turn = "a"
for i in range(300):
if turn == "a":
if A != "":
turn = A[0]
A = A[1:]
else:
print("A")
exit()
elif turn == "b":
if B != "":
turn = B[0]
B = B[1:]
else:
print("B")
exit()
elif turn == "c":
if C != "":
turn = C[0]
C = C[1:]
else:
print("C")
exit() | Traceback (most recent call last):
File "/tmp/tmpffbhzopb/tmpu2mjs5ft.py", line 3, in <module>
stdin = open("sample.txt")
^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: 'sample.txt'
| |
s981639548 | p03998 | u853900545 | 1539135929 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 413 | sb = list(input())
sc = list(input())
d = sa[0]
while 1:
if d == 'a':
sa = sa.pop(0)
if sa == []:
print('A')
break
d = sa[0]
elif d == 'b':
sb = sb.pop(0)
if sb == []:
print('B')
break
d = sb[0]
else:
sc = sc.pop(0)
if sc == []:
print('C')
break
d = sc[0] | Traceback (most recent call last):
File "/tmp/tmp1i6kod0a/tmpszjmd10r.py", line 1, in <module>
sb = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s565730232 | p03998 | u853900545 | 1539133821 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 378 | sa = list(input())
sb = list(input())
sc = list(input())
d = sa[0]
while (len(sa) == 0 or len(sb) == 0 or len(sc) == 0) == 0:
if d == 'a':
sa = sa[1::]
d = sa[0]
elif d == 'b':
sb = sb[1::]
d = sb[0]
else:
sc = sc[1::]
d = sc[0]
if len(sa) == 0:
print('A')
elif len(sb) == 0:
print('B')
else:
print('C') | Traceback (most recent call last):
File "/tmp/tmpvdojzzq9/tmpcxr8ta6n.py", line 1, in <module>
sa = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s490864775 | p03998 | u853900545 | 1539107471 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 333 | sa = list(input())
sb = list(input())
sc = list(input())
d = sa[0]
while d !=[]:
if d == 'a':
sa = sa[1::]
d = sa[0]
elif d == 'b':
sb = sb[1::]
d = sb[0]
else:
sc = sc[1::]
d = sc[0]
if len(sa) == 0:
print('A')
elif len(sb) == 0:
print('B')
else:
print('C') | Traceback (most recent call last):
File "/tmp/tmp0jfx98e6/tmppi8_2n33.py", line 1, in <module>
sa = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s762762193 | p03998 | u853900545 | 1539106419 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 378 | sa = list(input())
sb = list(input())
sc = list(input())
d = sa[0]
while (len(sa) == 0 or len(sb) == 0 or len(sc) == 0) == 0:
if d == 'a':
sa = sa[1::]
d = sa[0]
elif d == 'b':
sb = sb[1::]
d = sb[0]
else:
sc = sc[1::]
d = sc[0]
if len(sa) == 0:
print('A')
elif len(sb) == 0:
print('B')
else:
print('C') | Traceback (most recent call last):
File "/tmp/tmpvky75f80/tmpdsahxrca.py", line 1, in <module>
sa = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s888339758 | p03998 | u853900545 | 1539106066 | Python | Python (3.4.3) | py | Runtime Error | 19 | 3188 | 406 | sa = list(input())
sb = list(input())
sc = list(input())
cnta = len(sa)
cntb = len(sb)
cntc = len(sc)
d = sa[0]
while not(cnta == 0 or cntb == 0 or cntc == 0):
if d == 'a':
sa = sa[1::]
d = sa[0]
elif d == 'b':
sb = sb[1::]
d = sb[0]
else:
sc = sc[1::]
d = sc[0]
if cnta == 0:
print('A')
elif cntb == 0:
print('B')
else:
print('C') | Traceback (most recent call last):
File "/tmp/tmpy568miho/tmpfb3r08lh.py", line 1, in <module>
sa = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s668646186 | p03998 | u513081876 | 1538857408 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 781 | A = list(input())
B = list(input())
C = list(input())
ans = 1
if len(A) == 1 and A[0] == 'a':
print('A')
else:
card = A[0]
del A[0]
while ans == 1:
if card == 'a':
card = A[0]
del A[0]
if card == 'a' and len(A) == 0:
print('A')
ans = 0
elif card == 'b':
card = B[0]
del B[0]
if card == 'b' and len(B) == 0:
print('B')
ans = 0
elif card == 'c':
card = C[0]
del C[0]
if card == 'c' and len(C) == 0:
print('C')
ans = 0
| Traceback (most recent call last):
File "/tmp/tmpdx7lvauo/tmp51qn0j_0.py", line 1, in <module>
A = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s341529044 | p03998 | u513081876 | 1538857067 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 650 | A = list(input())
B = list(input())
C = list(input())
ans = 1
if len(A) == 0:
print(A)
else:
card = A[0]
del A[0]
while ans == 1:
if card == 'a':
card = A[0]
del A[0]
if card == 'a' and len(A) == 0:
print('A')
ans = 0
elif card == 'b':
card = B[0]
del B[0]
if card == 'b' and len(B) == 0:
print('B')
ans = 0
elif card == 'c':
card = C[0]
del C[0]
if card == 'c' and len(C) == 0:
print('C')
ans = 0 | Traceback (most recent call last):
File "/tmp/tmptvk77_hs/tmpcaew2jxi.py", line 1, in <module>
A = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s941314446 | p03998 | u474270503 | 1538182856 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3188 | 255 | sabc=[list(input()) for _ in range(3)]
abc=[0,0,0]
lsabc=['a','b','c']
lsABC=['A','B','C']
def func(n):
num=lsabc.index(sabc[n][abc[n]])
abc[num]+=1
if abc[num]==len(sabc[num])-1:
print(lsABC[num])
exit()
func(num)
func(0)
| Traceback (most recent call last):
File "/tmp/tmpwfv36x6a/tmp9w6uw6kl.py", line 1, in <module>
sabc=[list(input()) for _ in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpwfv36x6a/tmp9w6uw6kl.py", line 1, in <listcomp>
sabc=[list(input()) for _ in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s526313392 | p03998 | u466105944 | 1536775702 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3060 | 403 | def get_next(chr):
if chr == 'a':
return a_cards.pop(0)
elif chr == 'b':
return b_cards.pop(0)
elif chr == 'c':
return c_cards.pop(0)
a_cards = list(input())
b_cards = list(input())
c_cards = list(input())
card = a_cards.pop(0)
while len(a_cards) != 0 and len(b_cards) != 0 and len(c_cards) != 0:
card = get_next(card)
print(str.upper(get_next(card)))
| Traceback (most recent call last):
File "/tmp/tmpqt0k65e5/tmp97c_b29a.py", line 9, in <module>
a_cards = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s200280564 | p03998 | u787562674 | 1536378473 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 484 | A = input()
B = input()
C = input()
owner = 'a'
while True:
if owner == 'a'
if len(A):
owner = A[0]
del(A[0])
else:
print('a')
break
if owner == 'b'
if len(B):
owner = B[0]
del(B[0])
else:
print('b')
break
if owner == 'c'
if len(C):
owner = C[0]
del(C[0])
else:
print('c')
break | File "/tmp/tmpjbe8sfsr/tmp9ezz1xvd.py", line 8
if owner == 'a'
^
SyntaxError: expected ':'
| |
s660407454 | p03998 | u017810624 | 1536376750 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 245 | a,b,c=(list(input()) for x in range(3))
n=a.pop(0)
while not len(a)==0 or len(b)==0 or len(c)==0:
if n=='a':
n=a.pop(0)
elif n=='b':
n=b.pop(0)
else:
n=c.pop(0)
if a=='':print('A')
elif b=='':print('B')
else:print('C') | Traceback (most recent call last):
File "/tmp/tmp5hty46ad/tmppqfhl5bk.py", line 1, in <module>
a,b,c=(list(input()) for x in range(3))
^^^^^
File "/tmp/tmp5hty46ad/tmppqfhl5bk.py", line 1, in <genexpr>
a,b,c=(list(input()) for x in range(3))
^^^^^^^
EOFError: EOF when reading a line
| |
s349521104 | p03998 | u064408584 | 1535506030 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3060 | 323 | a=list(input())
b=list(input())
c=list(input())
oner='a'
while True:
if oner=='a':
if len(a)==0:break
oner=a.pop(0)
if oner=='b':
if len(c)==0:break
oner=b.pop(0)
if oner=='c':
if len(c)==0:break
oner=c.pop(0)
print(oner.upper) | Traceback (most recent call last):
File "/tmp/tmpjjol0w22/tmpuy9zbsin.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s983069480 | p03998 | u064408584 | 1535505999 | Python | Python (3.4.3) | py | Runtime Error | 20 | 3188 | 344 | a=list(input())
b=list(input())
c=list(input())
oner='a'
while True:
if oner=='a':
if len(a)==0:break
oner=a.pop(0)
if oner=='b':
if len(c)==0:break
oner=b.pop(0)
if oner=='c':
if len(c)==0:break
oner=c.pop(0)
print(a,b,c)
print(oner.upper) | Traceback (most recent call last):
File "/tmp/tmpxzfh7zke/tmpq55okkqm.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s991759194 | p03998 | u826263061 | 1533830167 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3060 | 251 | s=[]
s.append[list(input())]
s.append[list(input())]
s.append[list(input())]
name = 'ABC'
i = 0
while True:
if len(s[i]) == 0:
print(name[i])
break
c = s[i].pop(0)
if c == 'a':
i = 0
elif c == 'b':
i = 1
else:
i = 2
| Traceback (most recent call last):
File "/tmp/tmpx8lcsa0g/tmpai3q0e11.py", line 2, in <module>
s.append[list(input())]
^^^^^^^
EOFError: EOF when reading a line
| |
s636216296 | p03998 | u599547273 | 1532878459 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3060 | 232 | s_abc = [input().split for i in range(3)]
player = 0
while True:
next_player = "abc".find(s_abc[player][0])
s_abc[player] = s_abc[player][1:]
if 0 <= s_abc.index(""):
print("ABC"[s_abc.index("")])
break
player = next_player | Traceback (most recent call last):
File "/tmp/tmpn1vhiy_g/tmpf1ahqdek.py", line 1, in <module>
s_abc = [input().split for i in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpn1vhiy_g/tmpf1ahqdek.py", line 1, in <listcomp>
s_abc = [input().split for i in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s421514674 | p03998 | u627417051 | 1531456953 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 367 | Sa = list(input())
Sb = list(input())
Sc = list(input())
turn = "a"
while True:
if turn == "a":
if Sa == "":
print("A")
break
else:
Sa.remove(Sa[0])
turn = "a"
if turn == "b":
if Sb == "":
print("B")
break
else:
Sb.remove(Sb[0])
turn = "b"
if turn == "c":
if Sa == "":
print("C")
break
else:
Sc.remove(Sc[0])
turn = "c" | Traceback (most recent call last):
File "/tmp/tmpi6jeom4l/tmpfyma8ics.py", line 1, in <module>
Sa = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s353173964 | p03998 | u136395536 | 1529836740 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 788 | SA = input()
SB = input()
SC = input()
A = []
for i in range(len(SA)):
tmp = SA[i]
A.append(tmp)
B = []
for i in range(len(SB)):
tmp = SB[i]
B.append(tmp)
C = []
for i in range(len(SC)):
tmp = SC[i]
C.append(tmp)
suteru = A[0]
A.remove(A[0])
lenA = len(A)
have = True
while have:
if suteru == "a":
suteru = A[0]
A.remove(A[0])
if len(A) == 0:
moji = "A"
have = False
elif suteru == "b":
suteru = B[0]
B.remove(B[0])
if len(B) == 0:
moji = "B"
have = False
elif suteru == "c":
suteru == C[0]
C.remove(C[0])
if len(C) == 0:
moji = "C"
have = False
if lenA == 1:
print("A")
else:
print(moji)
| Traceback (most recent call last):
File "/tmp/tmpu6kfhxmx/tmp1t69v5tx.py", line 1, in <module>
SA = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s524228437 | p03998 | u108808596 | 1529554712 | Python | Python (2.7.6) | py | Runtime Error | 10 | 2568 | 229 | s = {}
s['a']=raw_input()
s['b']=raw_input()
s['c']=raw_input()
def solve(s):
turn = 'a'
while True:
if len(s[turn]) == 0:
return turn.upper()
nxt, s[turn] = s[turn][0], s[turn][1:]
turn = nxt
print solve(s) | File "/tmp/tmpjlcf6hxu/tmpya28sdr8.py", line 11
turn = nxt
TabError: inconsistent use of tabs and spaces in indentation
| |
s811203429 | p03998 | u108808596 | 1529554534 | Python | Python (2.7.6) | py | Runtime Error | 10 | 2568 | 229 | s = {}
s['a']=raw_input()
s['b']=raw_input()
s['c']=raw_input()
def solve(s):
turn = 'a'
while True:
nxt, s[turn] = s[turn][0], s[turn][1:]
if len(s[turn]) == 0:
return turn.upper()
turn = nxt
print solve(s) | File "/tmp/tmphfbxr4uq/tmp_wvt05vu.py", line 11
turn = nxt
TabError: inconsistent use of tabs and spaces in indentation
| |
s138631831 | p03998 | u459283268 | 1528603262 | Python | Python (3.4.3) | py | Runtime Error | 18 | 2940 | 143 | d = dict(a=input(), b=input(), c=input())
op = 'a'
while True:
if not d[op]:
print(op.upper())
break
op = d[op].pop(0)
| Traceback (most recent call last):
File "/tmp/tmp1ucbhgpd/tmp6j02ld9r.py", line 1, in <module>
d = dict(a=input(), b=input(), c=input())
^^^^^^^
EOFError: EOF when reading a line
| |
s831650266 | p03998 | u894440853 | 1528476591 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 293 | S_a, S_b, S_c = [input() for _ in range(3)]
trun = 'a'
relation = {'a': S_a, 'b': S_b, 'c': S_c}
while True:
card = relaton[turn].pop(0)
turn = card
if len(S_a) == 0:
print('A')
exit()
if len(S_b) == 0:
print('B')
exit()
if len(S_c) == 0:
print('C')
exit() | Traceback (most recent call last):
File "/tmp/tmphgkpqdor/tmp0so3732g.py", line 1, in <module>
S_a, S_b, S_c = [input() for _ in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmphgkpqdor/tmp0so3732g.py", line 1, in <listcomp>
S_a, S_b, S_c = [input() for _ in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s930054911 | p03998 | u856232850 | 1523844005 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 414 | a = input()
b = input()
c = input()
d = a[0]
a.pop(0)
while True:
if d == "a":
if len(a) == 0:
print("A")
break
d = a[0]
a.pop(0)
if d == "b":
if len(b) == 0:
print("B")
break
d = b[0]
b.pop(0)
if d == "c":
if len(c) == 0:
print("C")
break
d = c[0]
c.pop(0) | Traceback (most recent call last):
File "/tmp/tmpa557iug5/tmpgf1w15qf.py", line 1, in <module>
a = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s664957259 | p03998 | u978494963 | 1523828485 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 522 |
def game(a, b, c, current="a"):
if current == "a":
if len(a)==0:
return "A"
else:
current = a.pop(0)
return game(a,b,c,current)
elif current == "b":
if len(b) == 0:
return "B"
else:
current = b.pop(0)
return game(a,b,c,current)
else:
if len(c) == 0:
return "C"
else:
current = c.pop(0)
return game(a,b,c,current)
if __name__ == '__main__':
a = input()
b = input()
c = input()
print(game(a,b,c)) | File "/tmp/tmpedm6qqsb/tmphinr4mso.py", line 4
if len(a)==0:
^
IndentationError: unindent does not match any outer indentation level
| |
s980003457 | p03998 | u766407523 | 1523396478 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3060 | 156 | d = {a:input(), b:input(), c:input()}
temp = 'a'
while True:
if d[temp] == '':
break
d[temp] = d[temp][1:]
temp = d[temp][0]
print(temp) | Traceback (most recent call last):
File "/tmp/tmpol2y8y6c/tmpxnrcpvzr.py", line 1, in <module>
d = {a:input(), b:input(), c:input()}
^
NameError: name 'a' is not defined
| |
s849400964 | p03998 | u030726788 | 1519365248 | Python | Python (3.4.3) | py | Runtime Error | 19 | 3188 | 344 | Sa=list(input())
Sb=list(input())
Sc=list(input())
Sa.pop()
Sb.pop()
#Sc.pop()
S=Sa.pop(0)
Win="A"
while(S!=""):
if(S=="a"):
S=""
if(len(Sa)!=0):
S=Sa.pop(0)
Win="A"
elif(S=="b"):
S=""
if(len(Sb)!=0):
S=Sb.pop(0)
Win="B"
elif(S=="c"):
S=""
if(len(Sc)!=0):
S=Sc.pop(0)
Win="C"
print(Win)
| Traceback (most recent call last):
File "/tmp/tmpnjzyv3aw/tmpure7xyoi.py", line 1, in <module>
Sa=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s847588099 | p03998 | u030726788 | 1519358116 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 344 | Sa=list(input())
Sb=list(input())
Sc=list(input())
Sa.pop()
Sb.pop()
#Sc.pop()
S=Sa.pop(0)
Win="A"
while(S!=""):
if(S=="a"):
S=""
if(len(Sa)!=0):
S=Sa.pop(0)
Win="A"
elif(S=="b"):
S=""
if(len(Sb)!=0):
S=Sb.pop(0)
Win="B"
elif(S=="c"):
S=""
if(len(Sc)!=0):
S=Sc.pop(0)
Win="C"
print(Win)
| Traceback (most recent call last):
File "/tmp/tmpdqzqp0it/tmp02b5ag7_.py", line 1, in <module>
Sa=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s539086298 | p03998 | u030726788 | 1519358067 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 342 | Sa=list(input())
Sb=list(input())
Sc=list(input())
Sa.pop()
Sb.pop()
Sc.pop()
S=Sa.pop(0)
Win="A"
while(S!=""):
if(S=="a"):
S=""
if(len(Sa)!=0):
S=Sa.pop(0)
Win="A"
elif(S=="b"):
S=""
if(len(Sb)!=0):
S=Sb.pop(0)
Win="B"
elif(S=="c"):
S=""
if(len(Sc)!=0):
S=Sc.pop(0)
Win="C"
print(Win) | Traceback (most recent call last):
File "/tmp/tmplqjkushn/tmpoeq_vqnz.py", line 1, in <module>
Sa=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s174182913 | p03998 | u030726788 | 1519357505 | Python | Python (3.4.3) | py | Runtime Error | 17 | 2940 | 218 | Sa=list(input())
Sb=list(input())
Sc=list(input())
S=Sa.pop(0)
Win=""
while(S):
if(S=="a"):
S=Sa.pop(0)
Win="A"
elif(S=="b"):
S=Sb.pop(0)
Win="B"
elif(S=="c"):
S=Sc.pop(0)
Win="C"
print(Win) | File "/tmp/tmpgg8i3edk/tmpjnozbshb.py", line 12
Win="B"
TabError: inconsistent use of tabs and spaces in indentation
| |
s694622072 | p03998 | u124139453 | 1518076456 | Python | Python (2.7.6) | py | Runtime Error | 11 | 2568 | 308 | Sa = list(raw_input())
Sb = list(raw_input())
Sc = list(raw_input())
ne = Sa.pop(0)
s = len(Sa)
while s!=0:
if ne == "a":
ne = Sa.pop(0)
s = len(Sa)
if ne == "b":
ne = Sb.pop(0)
s = len(Sb)
if ne == "c":
ne = Sc.pop(0)
s = len(Sc)
print ne.upper() | File "/tmp/tmpywj0sioh/tmpuhon0zt8.py", line 17
print ne.upper()
^^^^^^^^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
| |
s939052129 | p03998 | u124139453 | 1518076093 | Python | Python (2.7.6) | py | Runtime Error | 11 | 2568 | 264 | Sa = list(raw_input())
Sb = list(raw_input())
Sc = list(raw_input())
ne = Sa.pop(0)
s = len(Sa)
while s!=0:
if ne == "a":
ne = Sa.pop(0)
if ne == "b":
ne = Sb.pop(0)
if ne == "c":
ne = Sc.pop(0)
s = len(Sa)
print ne.upper() | File "/tmp/tmpmzs8ns8f/tmphc4_17gg.py", line 15
print ne.upper()
^^^^^^^^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
| |
s706002561 | p03998 | u124139453 | 1518076012 | Python | Python (2.7.6) | py | Runtime Error | 10 | 2568 | 256 | Sa = list(raw_input())
Sb = list(raw_input())
Sc = list(raw_input())
ne = Sa.pop(0)
s = len(Sa)
while s!=0:
if ne == "a":
ne = Sa.pop(0)
if ne == "b":
ne = Sb.pop(0)
if ne == "c":
ne = Sc.pop(0)
s = len(Sa)
print ne | File "/tmp/tmp5nl4mnms/tmp7p8l5qae.py", line 15
print ne
^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
| |
s789759111 | p03998 | u202877219 | 1516607463 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3060 | 127 | x,y,z = map(int, input().split())
if z == y == z:
print ("1")
elif x == y or y == z:
print ("2")
else:
print ("3") | Traceback (most recent call last):
File "/tmp/tmp93lvztko/tmp3n4xp2je.py", line 1, in <module>
x,y,z = map(int, input().split())
^^^^^^^
EOFError: EOF when reading a line
| |
s104356149 | p03998 | u143492911 | 1515263696 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 433 | a=list(input())
b=list(input())
c=list(input())
next=a[0]
del a[0]
while True:
if len(a)==0 and next=="a":
print("A")
break
if len(b)==0 and next=="b":
print("B")
break
if len(c)==0 and next=="c":
print("C")
break
if next=="a":
next=a[0]
del a[0]
if next=="b":
next=b[0]
del b[0]
if next=="c":
next=c[0]
del c[0]
| Traceback (most recent call last):
File "/tmp/tmp_mp5kh24/tmpx2cm79st.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s791934034 | p03998 | u143492911 | 1515260715 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 432 | a=list(input())
b=list(input())
c=list(input())
next=a[0]
del a[0]
while True:
if next=="a":
next=a[0]
del a[0]
if next=="b":
next=b[0]
del b[0]
if next=="c":
next=c[0]
del c[0]
if len(a)==0 and next=="a":
print("A")
break
if len(b)==0 and next=="b":
print("B")
break
if len(c)==0 and next=="c":
print("C")
break | Traceback (most recent call last):
File "/tmp/tmphtzg3pwp/tmptzj2q2cz.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s953509527 | p03998 | u143492911 | 1515260122 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 432 | a=list(input())
b=list(input())
c=list(input())
next=a[0]
del a[0]
while True:
if next=="a":
next=a[0]
del a[0]
if next=="b":
next=b[0]
del b[0]
if next=="c":
next=c[0]
del c[0]
if len(a)==0 and next=="a":
print("A")
break
if len(b)==0 and next=="b":
print("B")
break
if len(c)==0 and next=="c":
print("C")
break | Traceback (most recent call last):
File "/tmp/tmpnhzxb2sx/tmpng3psmqm.py", line 1, in <module>
a=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s665773564 | p03998 | u143492911 | 1514673198 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 490 | sa=list(input())
sb=list(input())
sc=list(input())
owner="a"
while True:
if owner=="a":
if len(A):
owner=A[0]
del A[0]
else:
break
elif owner=="b":
if len(B):
owner=B[0]
del B[0]
else:
break
else:
if len(C):
owner=C[0]
del C[0]
else:
break
if owner=="a":
print("A")
elif owner=="b":
print("B")
else:
print("C") | Traceback (most recent call last):
File "/tmp/tmpcaxwzk3d/tmpv2ard138.py", line 1, in <module>
sa=list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s570866335 | p03998 | u750032608 | 1512329405 | Python | Python (2.7.6) | py | Runtime Error | 10 | 2568 | 409 | sa = str(raw_input())
sb = str(raw_input())
sc = str(raw_input())
n = 'a'
h = ''
while True:
if n = 'a':
if len(sa) < 1:
break
h, sa = sa[0], sa[1:]
n = h
elif n = 'b':
if len(sb) < 1:
break
h, sb = sb[0], sb[1:]
n = h
elif n = 'c':
if len(sc):
break
h, sc = sc[0], sc[1:]
n = h
print n
| File "/tmp/tmp6srvhgwu/tmpjiyyz0ey.py", line 8
if n = 'a':
^^^^^^^
SyntaxError: invalid syntax. Maybe you meant '==' or ':=' instead of '='?
| |
s532720534 | p03998 | u809670194 | 1497314556 | Python | Python (3.4.3) | py | Runtime Error | 17 | 3064 | 808 | a = list(input())
b = list(input())
c = list(input())
target = a
while a!="" and b!="" and c!="":
if target == a:
if len(a) == 0:
win = "A"
break
if a[0] == "a":
target = a
elif a[0] == "b":
target = b
else:
target = c
a.pop(0)
elif target[0] == "b":
if len(b) == 0:
win = "B"
break
if b[0] == "a":
target = a
elif b[0] == "b":
target = b
else:
target = c
b.pop(0)
else:
if len(c) == 0:
win = "C"
break
if c[0] == "a":
target = a
elif c[0] == "b":
target = b
else:
target = c
c.pop(0)
print(win) | Traceback (most recent call last):
File "/tmp/tmpwdqiwqha/tmp8c9rqt8d.py", line 1, in <module>
a = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s765869506 | p03998 | u809670194 | 1497314239 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 817 | a = list(input())
b = list(input())
c = list(input())
target = a
while a!="" and b!="" and c!="":
if target == a:
if len(a) == 0:
win = "A"
break
if a[0] == "a":
target = a
elif a[0] == "b":
target = b
else:
target == "c"
a.pop(0)
elif target[0] == "b":
if len(b) == 0:
win = "B"
break
if b[0] == "a":
target = a
elif b[0] == "b":
target = b
else:
target == "c"
b.pop()
else:
if len(c) == 0:
win = "C"
break
if c[0] == "a":
target = a
elif c[0] == "b":
target = b
else:
target == "c"
c.pop()
print(win)
| Traceback (most recent call last):
File "/tmp/tmp4_ysjydo/tmpqeqakqo3.py", line 1, in <module>
a = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s745207816 | p03998 | u809670194 | 1497312319 | Python | Python (3.4.3) | py | Runtime Error | 21 | 2940 | 378 | a = input()
b = input()
c = input()
target = a
while a!="" and b!="" and c!="":
if target[0] == "a":
a.pop(0)
if a == "":
print("a")
target = a
elif target[0] = "b":
b.pop(0)
if b == "":
print("b")
target = b
else:
c.pop(0)
if c == "":
print("c")
target = c | File "/tmp/tmplqxzzgl0/tmpq4_1i3xp.py", line 12
elif target[0] = "b":
^^^^^^^^^
SyntaxError: cannot assign to subscript here. Maybe you meant '==' instead of '='?
| |
s892269121 | p03998 | u973712798 | 1479265130 | Python | PyPy3 (2.4.0) | py | Runtime Error | 228 | 38896 | 542 | sa = [st for st in input().split()]
sb = [string for string in input().split()]
sc = [string for string in input().split()]
flag = False
nxt = "a"
while flag == False:
if len(sa) == 0:
print("a")
break
elif len(sb) == 0:
print("b")
break
elif len(sc) == 0:
print("c")
break
if nxt == "a":
nxt = target.pop(0)
target = sa
elif nxt == "b":
nxt = target.pop(0)
target = sb
elif nxt == "c":
nxt = target.pop(0)
target = sc
| Traceback (most recent call last):
File "/tmp/tmph9pbwwz_/tmpv2hjrlni.py", line 1, in <module>
sa = [st for st in input().split()]
^^^^^^^
EOFError: EOF when reading a line
| |
s848229449 | p03998 | u973712798 | 1479265091 | Python | PyPy3 (2.4.0) | py | Runtime Error | 234 | 40304 | 544 | sa = [st for st in input().split()]
sb = [string for string in input().split()]
sc = [string for string in input().split()]
flag = False
target = sa
while flag == False:
if len(sa) == 0:
print("a")
break
elif len(sb) == 0:
print("b")
break
elif len(sc) == 0:
print("c")
break
if nxt == "a":
nxt = target.pop(0)
target = sa
elif nxt == "b":
nxt = target.pop(0)
target = sb
elif nxt == "c":
nxt = target.pop(0)
target = sc
| Traceback (most recent call last):
File "/tmp/tmpqp1c4aak/tmp6zdc2a63.py", line 1, in <module>
sa = [st for st in input().split()]
^^^^^^^
EOFError: EOF when reading a line
| |
s005140099 | p03998 | u145790740 | 1477696070 | Python | Python (2.7.6) | py | Runtime Error | 16 | 2568 | 236 | player_list = ['a', 'b', 'c']
s = {player_list[n]: list(raw_input()) for n in player_list}
current_turn = player_list[0]
get_winner = lambda x, s: not s[x] and x.upper() or get_winner(s[x].pop(0), s)
print get_winner(current_turn, s) | File "/tmp/tmpmv3msdrt/tmpsjtz0622.py", line 8
print get_winner(current_turn, s)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
| |
s195096427 | p03998 | u580920947 | 1477537228 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 223 |
# -*- coding: utf-8 -*-
# problem B
player = {i:list(input()) for i in 'abc'}
t = 'a'
while True:
if len(player[t]) == 0:
break
else:
x = p[t][0]
p[t].pop(0)
t = x
print(t.upper()) | Traceback (most recent call last):
File "/tmp/tmpwngz0gpg/tmpfdec4dn7.py", line 4, in <module>
player = {i:list(input()) for i in 'abc'}
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmpwngz0gpg/tmpfdec4dn7.py", line 4, in <dictcomp>
player = {i:list(input()) for i in 'abc'}
^^^^^^^
EOFError: EOF when reading a line
| |
s202454257 | p03998 | u541921833 | 1476567911 | Python | Python (2.7.6) | py | Runtime Error | 17 | 2568 | 489 | a = str(raw_input())
b = str(raw_input())
c = str(raw_input())
if len(a) == 1:
print 'a'
return
s = a[0]
a = a[1:]
while True:
if s == 'a':
if len(a) == 1:
print 'a'
break
s = a[0]
a = a[1:]
elif s == 'b':
if len(b) == 1:
print 'b'
break
s = b[0]
b = b[1:]
elif s == 'c':
if len(c) == 1:
print 'c'
break
s = c[0]
c = c[1:]
| File "/tmp/tmpbrv_kxsd/tmpoki42m48.py", line 6
print 'a'
^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
| |
s664203691 | p03998 | u276144769 | 1474737978 | Python | Python (3.4.3) | py | Runtime Error | 23 | 3064 | 186 | s={}
for i in range(3):
s[chr(97+i)]=input()
turn="a"
while True:
if not s[turn]:
break
else:
turn=s[turn[0]]
s[turn]=s[turn][1:]
print(turn.upper())
| Traceback (most recent call last):
File "/tmp/tmpjz78aayq/tmp2589fbni.py", line 3, in <module>
s[chr(97+i)]=input()
^^^^^^^
EOFError: EOF when reading a line
| |
s174496770 | p03998 | u317493066 | 1474550869 | Python | Python (2.7.6) | py | Runtime Error | 26 | 2568 | 764 | # -*- coding:utf-8 -*-
if __name__ == "__main__":
# input
a = raw_input()
b = raw_input()
c = raw_input()
a_index = 0
b_index = 0
c_index = 0
next_user = a[a_index]
a_index += 1
while(True):
if next_user == 'a':
next_user = a[a_index]
a_index = a_index + 1
if len(a) == a_index:
print 'A'
break
elif next_user == 'b':
next_user = b[b_index]
b_index = b_index + 1
if len(b) == b_index:
print 'B'
break
else:
next_user = c[c_index]
c_index = c_index + 1
if len(c) == c_index:
print 'C'
break
| File "/tmp/tmp4bcro0oz/tmpn6cu_isx.py", line 22
print 'A'
^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
| |
s726714125 | p03998 | u091855288 | 1473691912 | Python | Python (3.4.3) | py | Runtime Error | 410 | 23076 | 568 | import numpy as np
Sa = input()
Sb = input()
Sc = input()
def string2int(in_list):
out_list = np.array(in_list, dtype='S')
out_list[out_list=='a'] = 0
out_list[out_list=='b'] = 1
out_list[out_list=='c'] = 2
return np.array(out_list, dtype=int)
Sa = string2int(list(Sa))
Sb = string2int(list(Sb))
Sc = string2int(list(Sc))
ALL = [list(Sa), list(Sb), list(Sc)]
current = 0
pre = 0
while True:
left = len(ALL[current])
if left == 0:
break
current = ALL[current][0]
ALL[pre] = ALL[pre][1:]
pre = current
cor = ['A','B','C']
print( cor[current] ) | Traceback (most recent call last):
File "/tmp/tmpd3aflqb1/tmptev7fy80.py", line 2, in <module>
Sa = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s386303086 | p03998 | u125205981 | 1473646936 | Python | Python (3.4.3) | py | Runtime Error | 38 | 3064 | 468 | a = list(input())
b = list(input())
c = list(input())
n = a[0]
del a[0]
if len(a) == 0:
print("A")
while True:
if n == "a":
n = a[0]
del a[0]
if len(a) == 0:
print("A")
break
elif n == "b":
n = b[0]
del b[0]
if len(b) == 0:
print("B")
break
elif n == "c":
n = c[0]
del c[0]
if len(c) == 0:
print("C")
break
| Traceback (most recent call last):
File "/tmp/tmp49r_wtiy/tmp3t47ew20.py", line 1, in <module>
a = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s320871334 | p03998 | u125205981 | 1473646677 | Python | Python (3.4.3) | py | Runtime Error | 42 | 3064 | 478 | a = list(input())
b = list(input())
c = list(input())
n = a[0]
del a[0]
if len(a) == 0:
print("A")
break
while True:
if n == "a":
n = a[0]
del a[0]
if len(a) == 0:
print("A")
break
elif n == "b":
n = b[0]
del b[0]
if len(b) == 0:
print("B")
break
elif n == "c":
n = c[0]
del c[0]
if len(c) == 0:
print("C")
break
| File "/tmp/tmpibstwp3w/tmpyyhbjbhx.py", line 9
break
^^^^^
SyntaxError: 'break' outside loop
| |
s490075806 | p03998 | u863846890 | 1473646610 | Python | Python (3.4.3) | py | Runtime Error | 39 | 3064 | 250 | A = raw_input()
B = raw_input()
C = raw_input()
cnt = {'a': 0, 'b': 0, 'c': 0}
S = {'a': A, 'b': B, 'c': C}
turn = 'a'
while True:
if cnt[turn] >= len(S[turn]):
break
pop = S[turn][cnt[turn]]
cnt[turn] += 1
turn = pop
print(turn.upper())
| Traceback (most recent call last):
File "/tmp/tmpqsp1sltx/tmpi4oiafus.py", line 1, in <module>
A = raw_input()
^^^^^^^^^
NameError: name 'raw_input' is not defined
| |
s692887060 | p03998 | u863846890 | 1473646419 | Python | Python (3.4.3) | py | Runtime Error | 43 | 3064 | 250 | A = raw_input()
B = raw_input()
C = raw_input()
cnt = {'a': 0, 'b': 0, 'c': 0}
S = {'a': A, 'b': B, 'c': C}
turn = 'a'
while True:
if cnt[turn] >= len(S[turn]):
break
pop = S[turn][cnt[turn]]
cnt[turn] += 1
turn = pop
print(turn.upper())
| Traceback (most recent call last):
File "/tmp/tmpvph9atmf/tmp02c5fp5u.py", line 1, in <module>
A = raw_input()
^^^^^^^^^
NameError: name 'raw_input' is not defined
| |
s522294389 | p03998 | u863846890 | 1473646303 | Python | Python (3.4.3) | py | Runtime Error | 38 | 3064 | 242 | A = raw_input()
B = raw_input()
C = raw_input()
cnt = {'a': 0, 'b': 0, 'c': 0}
S = {'a': A, 'b': B, 'c': C}
turn = 'a'
while True:
if cnt[turn] >= len(S[turn]):
break
pop = S[turn][cnt[turn]]
cnt[turn] += 1
turn = pop
print(turn)
| Traceback (most recent call last):
File "/tmp/tmptmqvgxjb/tmp8uof1mje.py", line 1, in <module>
A = raw_input()
^^^^^^^^^
NameError: name 'raw_input' is not defined
| |
s601117503 | p03998 | u863846890 | 1473646264 | Python | Python (3.4.3) | py | Runtime Error | 39 | 3064 | 251 | A = raw_input()
B = raw_input()
C = raw_input()
cnt = {'a': 0, 'b': 0, 'c': 0}
S = {'a': A, 'b': B, 'c': C}
turn = 'a'
print(S)
while True:
if cnt[turn] >= len(S[turn]):
break
pop = S[turn][cnt[turn]]
cnt[turn] += 1
turn = pop
print(turn)
| Traceback (most recent call last):
File "/tmp/tmpp2lz80gp/tmpbkvfmrap.py", line 1, in <module>
A = raw_input()
^^^^^^^^^
NameError: name 'raw_input' is not defined
| |
s906417159 | p03998 | u125205981 | 1473646216 | Python | Python (3.4.3) | py | Runtime Error | 39 | 3064 | 437 | a = list(input())
b = list(input())
c = list(input())
n = a[0]
del a[0]
while True:
if n == "a":
n = a[0]
del a[0]
if len(a) == 0:
print("A")
break
elif n == "b":
n = b[0]
del b[0]
if len(b) == 0:
print("B")
break
elif n == "c":
n = c[0]
del c[0]
if len(c) == 0:
print("C")
break
| Traceback (most recent call last):
File "/tmp/tmpzehx7ziv/tmppnlilcjt.py", line 1, in <module>
a = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s358188757 | p03998 | u863846890 | 1473646133 | Python | Python (3.4.3) | py | Runtime Error | 41 | 3064 | 273 | A = raw_input()
B = raw_input()
C = raw_input()
cnt = {'a': 0, 'b': 0, 'c': 0}
S = {'a': A, 'b': B, 'c': C}
turn = 'a'
print(S)
while True:
if cnt[turn] >= len(S[turn]):
break
pop = S[turn][cnt[turn]]
cnt[turn] += 1
print(turn, pop, cnt)
turn = pop
print(turn) | Traceback (most recent call last):
File "/tmp/tmp_n1nkweq/tmpoctgvos9.py", line 1, in <module>
A = raw_input()
^^^^^^^^^
NameError: name 'raw_input' is not defined
| |
s608463007 | p03998 | u297770230 | 1473643481 | Python | PyPy3 (2.4.0) | py | Runtime Error | 350 | 43248 | 460 | lstA = list(input())
lstB = list(input())
lstC = list(input())
maxA = len(lstA)
maxB = len(lstB)
maxC = len(lstB)
numA = 0
numB = 0
numC = 0
res = ''
tmp = 'a'
while True:
if tmp == 'a':
if numA == maxA:
res = 'A'
break
tmp = lstA[numA]
numA += 1
elif tmp == 'b':
if numB == maxB:
res = 'B'
break
tmp = lstB[numB]
numB += 1
elif tmp == 'c':
if numC == maxC:
res = 'C'
break
tmp = lstC[numC]
numC += 1
print(res)
| Traceback (most recent call last):
File "/tmp/tmppxl25493/tmp8j11e7hh.py", line 1, in <module>
lstA = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s416275895 | p03998 | u566924053 | 1473643222 | Python | Python (3.4.3) | py | Runtime Error | 39 | 3064 | 427 |
sa, sb, sc = [list(input()) for i in range(3)]
now = sa.pop(0)
while 1:
#print(now, sa, sb, sc)
if now == "a":
now = sa.pop(0)
elif now == "b":
now = sb.pop(0)
else:
now = sc.pop(0)
if sa == [] and now == "a" :
print("A")
break
elif sb == [] and now == "b":
print("B")
break
elif sc == [] and now == "c":
print("C")
break | Traceback (most recent call last):
File "/tmp/tmp_j41wmyr/tmpu1epeiyc.py", line 2, in <module>
sa, sb, sc = [list(input()) for i in range(3)]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/tmp/tmp_j41wmyr/tmpu1epeiyc.py", line 2, in <listcomp>
sa, sb, sc = [list(input()) for i in range(3)]
^^^^^^^
EOFError: EOF when reading a line
| |
s016795967 | p03998 | u866746776 | 1473642531 | Python | Python (3.4.3) | py | Runtime Error | 42 | 2940 | 477 | def solve(a,b,c,turn):
if turn == "a":
if a == "":
return "A"
else:
next_turn = a[0]
a = a[1:]
elif turn == "b":
if b == "":
return "B"
else:
next_turn = b[0]
b = b[1:]
else
if c == "":
return "C"
else:
next_turn = c[0]
c = c[1:]
return solve(a,b,c, next_turn)
a=input().strip()
b=input().strip()
c=input().strip()
print(solve(a,b,c,"a")) | File "/tmp/tmp34lios57/tmpij11itda.py", line 1
def solve(a,b,c,turn):
IndentationError: unexpected indent
| |
s078194265 | p03998 | u866746776 | 1473642468 | Python | Python (3.4.3) | py | Runtime Error | 41 | 3064 | 381 | def solve(a,b,c,turn):
if turn == "a":
if a == "":
return "A"
else:
next_turn = a[0]
a = a[1:]
elif turn == "b":
if b == "":
return "B"
else:
next_turn = b[0]
b = b[1:]
else
if c == "":
return "C"
else:
next_turn = c[0]
c = c[1:]
return solve(a,b,c, next_turn)
a=input().strip()
b=input().strip()
b=input().strip()
print(solve(a,b,c,"a")) | File "/tmp/tmpyfm5dtb7/tmpqrv537sa.py", line 14
else
^
SyntaxError: expected ':'
| |
s068634235 | p03999 | u620846115 | 1600883753 | Python | Python (3.8.2) | py | Runtime Error | 25 | 9060 | 132 | n = input()
l = len(n)
ans = 0
for i in range(l):
for j in range(l-i):
ans+=int(n[i]) * 10**j * 2**i * 2**(n-i-j-2)
print(ans) | Traceback (most recent call last):
File "/tmp/tmp030_nn48/tmpud2p2fhx.py", line 1, in <module>
n = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s621676359 | p03999 | u383025592 | 1599341685 | Python | PyPy3 (7.3.0) | py | Runtime Error | 89 | 74516 | 304 | S = input()
num = 0
bits = format(num , 'b').zfill(len(S) - 1)
ans = 0
for i in range(2 ** (len(S) - 1)):
index = 0
for j in range(len(S) - 1):
if(bits[i] == 1):
ans += int(S[:i])
index = i + 1
ans += int(S[index:])
num += 1
bits = format(num , 2).zfill(len(S) - 1)
print(ans) | Traceback (most recent call last):
File "/tmp/tmp7ll4ahfj/tmpijae3adr.py", line 1, in <module>
S = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s571464259 | p03999 | u701658616 | 1599276208 | Python | Python (3.8.2) | py | Runtime Error | 20 | 8844 | 179 | fS = input()
n = len(S)
def dfs(i, f):
if i == n - 1:
return sum(list(map(int, f.split('+'))))
return dfs(i+1, f+S[i+1]) + dfs(i+1, f+'+'+S[i+1])
print(dfs(0, S[0])) | Traceback (most recent call last):
File "/tmp/tmp9zt1k807/tmp44c5k76t.py", line 1, in <module>
fS = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s235585145 | p03999 | u457601965 | 1598574523 | Python | Python (3.8.2) | py | Runtime Error | 23 | 9084 | 448 | import sys
import itertools
a, b, c, d = list(input())
lst = ['-', '+']
for i, j, k in itertools.product(range(2), range(2), range(2)):
ans = int(a)
if i:
ans += int(b)
else:
ans -= int(b)
if j:
ans += int(c)
else:
ans -= int(c)
if k:
ans += int(d)
else:
ans -= int(d)
if ans == 7:
print(a,lst[i],b,lst[j],c,lst[k],d,'=7',sep='')
sys.exit() | Traceback (most recent call last):
File "/tmp/tmpy4fuzngz/tmpvxjnxigm.py", line 5, in <module>
a, b, c, d = list(input())
^^^^^^^
EOFError: EOF when reading a line
| |
s923938201 | p03999 | u955248595 | 1598049259 | Python | Python (3.8.2) | py | Runtime Error | 32 | 9080 | 265 | from itertools import product
S = input()
if len(S)==1:
print(int(S))
else:
Sum = 0
for TR in product([0,1],repeat=(len(S)-1)):
Op = ['+' if TO==1 else '' for TO in TR]+['']
Sum += eval(''.join([TS+TO for TS,TO in zip(S,Op)]))
print(Sum) | Traceback (most recent call last):
File "/tmp/tmpp7upjnz1/tmpw_v727nc.py", line 2, in <module>
S = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s069792632 | p03999 | u267718666 | 1596398340 | Python | Python (3.8.2) | py | Runtime Error | 30 | 9176 | 334 | N = str(int(input()))
total = 0
l = len(N)-1
for i in range(2**l):
b = format(i, '0'+str(l)+'b')
subtotal = 0
s = N[0]
for j in range(len(b)):
if int(b[j]):
subtotal += int(s)
s = N[j+1]
else:
s += N[j+1]
subtotal += int(s)
total += subtotal
print(total) | Traceback (most recent call last):
File "/tmp/tmpw2mt3qf6/tmp285w7z35.py", line 1, in <module>
N = str(int(input()))
^^^^^^^
EOFError: EOF when reading a line
| |
s623242012 | p03999 | u697615293 | 1593896260 | Python | Python (3.8.2) | py | Runtime Error | 23 | 9124 | 184 | def dfs(i,f):
if i == n-1:
return sum(list(map(int,input().split("+"))))
return dfs(i+1,f+s[i+1]) + dfs[i+1,f + "+" + s[i+1]]
s = input()
n = len(s)
print(dfs(0,s[0])) | Traceback (most recent call last):
File "/tmp/tmpcl8bds4d/tmptfhr_haq.py", line 6, in <module>
s = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s538501217 | p03999 | u940139461 | 1593437528 | Python | PyPy3 (7.3.0) | py | Runtime Error | 91 | 74752 | 300 | # https://atcoder.jp/contests/abc045/tasks/arc061_a
s = input()
length = len(s)
ans = 0
for i in range(2 << length - 2):
temp = []
for j in range(length):
t = (i >> j) & 1
temp.append(s[j])
if t:
temp.append('+')
ans += eval(''.join(temp))
print(ans) | Traceback (most recent call last):
File "/tmp/tmpk8r26lku/tmp3xummzfd.py", line 3, in <module>
s = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s347617197 | p03999 | u600261652 | 1591666851 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3060 | 188 | def dfs(i, f):
if i == n:
return sum(list(map(int, f.split("+"))))
return dfs(i+1, f+s[i+1])+\
dfs(i+1, f+"+"+s[i+1])
s = input()
n = len(s)
print(dfs(0, s[0])) | Traceback (most recent call last):
File "/tmp/tmpsjvq6_v0/tmpwr7_e540.py", line 7, in <module>
s = input()
^^^^^^^
EOFError: EOF when reading a line
| |
s895219484 | p03999 | u154059173 | 1591238916 | Python | Python (3.4.3) | py | Runtime Error | 27 | 3064 | 309 | import sys
S = sys.stdin.readline()
number = [i for i in S]
N = len(number)
ans = 0
for bit in range(1<<(N-1)):
f = str(number[0])
for i in range(N-1):
if (bit&(1<<i)):
f = f+'+'+str(number[i+1])
else:
f = f+str(number[i+1])
ans = ans + eval(f)
print(ans) | Traceback (most recent call last):
File "/tmp/tmpgmk5u1lp/tmpwhda7tk9.py", line 7, in <module>
for bit in range(1<<(N-1)):
~^^~~~~~
ValueError: negative shift count
| |
s053402547 | p03999 | u386782537 | 1590767781 | Python | Python (3.4.3) | py | Runtime Error | 20 | 3064 | 373 | S =input()
ans_list = []
for i in range(2**(len(S)-1)):
comb = bin(i)[2:].zfill(len(S)-1)
num_list = []
num = S[0]
for i in range(len(comb)):
if comb[i] == "1":
num_list.append(int(num))
num = S[i+1]
else:
num += S[i+1]
num_list.append(int(num))
ans_list.append(sum(num_list))
print(sum(ans_list)) | Traceback (most recent call last):
File "/tmp/tmpiq7wo5zv/tmpdnpe11qx.py", line 1, in <module>
S =input()
^^^^^^^
EOFError: EOF when reading a line
| |
s806945232 | p03999 | u668503853 | 1590362505 | Python | Python (3.4.3) | py | Runtime Error | 18 | 3064 | 190 | S=input()
N=len(S)
ans=0
for i in range(2**(N-1)):
S=S[0]
q="{:0>10b}".format(i)[::-1]
for j in range(1,N):
if int(q[j-1])&1:
F+="+"
F+=S[j]
ans+=eval(F)
print(ans) | Traceback (most recent call last):
File "/tmp/tmp1pssx8us/tmp3f0g_6c9.py", line 1, in <module>
S=input()
^^^^^^^
EOFError: EOF when reading a line
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.