ZhenlongDai/ACPR huggingface dataset:
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):



 
import sys
import math



 

fileoperation=0
if(fileoperation):
    orig_stdout = sys.stdout
    orig_stdin = sys.stdin
    inputfile = open('W:/Competitive Programming/input.txt', 'r')
    outputfile = open('W:/Competitive Programming/output.txt', 'w')
    sys.stdin = inputfile
    sys.stdout = outputfile


mod=1000000007
 

def nospace(l):
    ans=''.join(str(i) for i in l)
    return ans
 
 
 

t=1
for tt in range(t):
    s=str(input())
    v=s.count('x')
    if(15-v<8):
        print("No")
    else:
        print("Yes")
    
    
    
    

if(fileoperation):
    sys.stdout = orig_stdout
    sys.stdin = orig_stdin
    inputfile.close()
    outputfile.close()

Failing test case input:
owoyowyoowowyo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):



 
import sys
import math



 

fileoperation=0
if(fileoperation):
    orig_stdout = sys.stdout
    orig_stdin = sys.stdin
    inputfile = open('W:/Competitive Programming/input.txt', 'r')
    outputfile = open('W:/Competitive Programming/output.txt', 'w')
    sys.stdin = inputfile
    sys.stdout = outputfile


mod=1000000007
 

def nospace(l):
    ans=''.join(str(i) for i in l)
    return ans
 
 
 

t=1
for tt in range(t):
    s=str(input())
    v=s.count('o')
    v+=15-len(s)
    if(v<8):
        print("NO")
    else:
        print("YES")
    
    
    
    

if(fileoperation):
    sys.stdout = orig_stdout
    sys.stdin = orig_stdin
    inputfile.close()
    outputfile.close()

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()
if S.count("x")>=8:
    print("No")
else:
    print("Yes")

Failing test case input:
oooyooyxoxxxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = input()
if S.count("x")>=8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
if s.count("○")<8:
    print("NO")
else:
    print("YES")


Failing test case input:
oxxxoooooxowxx

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=input()
if s.count("o")<8-(15-len(s)):
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

import sys
input = sys.stdin.readline

s = input()
if 15-len(s)+s.count('o') >= 8:
    ans = 'YES'
else:
    ans = 'NO'
print(ans)

Failing test case input:
owxoowoxoozxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()
if 15-len(s)+s.count('o') >= 8:
    ans = 'YES'
else:
    ans = 'NO'
print(ans)

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=input()

b=S.count('x')
print(b)
if((15-b)>=8):
    print("Yes")
else:
    print("No")


Failing test case input:
wxxowoooooxowy

Expected output:
YES


Actual output:
3
Yes


Fixed submission (verdict: Accepted):
S=input()

b=S.count('x')

if((15-b)>=8):
    print("YES")
else:
    print("NO")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
str1 = input() + "ooooooooooooooo"

count1 = 0

for i in range(15):
    if str1[i] == "o":
        count1 +=1

if count1 >= 8:
    print("yes")
else:
    print("no")

Failing test case input:
owoxowyoowoxyo

Expected output:
YES


Actual output:
yes


Fixed submission (verdict: Accepted):

str1 = input() + "ooooooooooooooo"

count1 = 0

for i in range(15):
    if str1[i] == "o":
        count1 +=1

if count1 >= 8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
str=input()
n=len(str)
count=0
for a in range(n):
    if str[a]== "o":
        count +=1

if count+15-n>=8:
    print("yes")
else:
    print("no")

Failing test case input:
xoyoxoxoyoxxoo

Expected output:
YES


Actual output:
yes


Fixed submission (verdict: Accepted):
str=input()
n=len(str)
count=0
for a in range(n):
    if str[a]== "o":
        count +=1

if count+15-n>=8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
n = input()
if n.count("o") < 8:
  print("YES")
else:
  print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
n = input()
if n.count("x") >= 8:
  print("NO")
else:
  print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
from sys import exit

S = input()

min_win = len(S) - 7

win_count = 0

for s in S:
    if s == 'o':
        win_count += 1

if win_count >= min_win:
    print('Yes')
else:
    print('No')


Failing test case input:
oxoxoyoxoxoxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
from sys import exit

S = input()

min_win = len(S) - 7

win_count = 0

for s in S:
    if s == 'o':
        win_count += 1

if win_count >= min_win:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = list(input())
if S.count("o") >= 8:
    print("YES")
else:
    print("NO")


Failing test case input:
owoxowzoowoxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
S = list(input())
k = len(S)
if S.count("o") + (15 - k) >= 8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
count = 0
for i in range(len(s)):
    if s[i] == "〇":
        count += 1
n = 15 - len(s) - count
if n > 0:
    print("YES")
else:
    print("no")


Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
s = input()
count = 0
for i in range(len(s)):
    if s[i] == "x":
        count += 1
n = 15 - count
if n >= 8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
if s.count("x")>=8:
  print("YES")
else:
  print("NO")

Failing test case input:
xoooyoxxxoxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=input()
if s.count("x")>=8:
  print("NO")
else:
  print("YES")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()

print('YES' if sum(s=='o' for s in S) >= 8 else 'NO')

Failing test case input:
oxxoxooxwoxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
S = input()


print('YES' if 15 - sum(s=='x' for s in S) >= 8 else 'NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
ct=0
for i in s:
  if i=='o':
    ct+=1
if 15-len(s)+ct>8:
  print('YES')
else:
  print('NO')

Failing test case input:
xoxoxooowoxzwo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=input()
ct=0
for i in s:
  if i=='o':
    ct+=1
if 15-len(s)+ct>=8:
  print('YES')
else:
  print('NO')

Problem: p03024
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
def solve():
    s = list(input())
    if s.count("o") >= 8:
        print("YES")
    else:
        print("NO")
    return 0

if __name__ == "__main__":
    solve()


Failing test case input:
owoxowooowxxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
def solve():
    s = input()
    k = len(s)
    if s.count("o")+(15-k) >= 8:
        print("YES")
    else:
        print("NO")
    return 0

if __name__ == "__main__":
    solve()

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=str(input())
N=8-S.count('o')
n=15-len(S)
if n>=N:
    print('Yes')
else:
    print('No')

Failing test case input:
xoyxwoxoxoooxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S=str(input())
N=8-S.count('o')
n=15-len(S)
if n>=N:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
S=list(input())
a=0
for i in range(len(S)):
    if S[i]=='x':
        a+=1
if a<=7:
    print('YES')
else:
    print('No')

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
No


Fixed submission (verdict: Accepted):
S=list(input())
a=0
for i in range(len(S)):
    if S[i]=='x':
        a+=1
if a<=7:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
from sys import stdin

s = stdin.readline().rstrip()
point = 0
for i in s:
    if i == "×":
        point += 1
if point >= 8:
    print("NO")
else:
    print("YES")


Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
from sys import stdin

s = stdin.readline().rstrip()
point = 0
for i in s:
    if i == "x":
        point += 1
if point >= 8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
match=list(input())
lmatch=len(match)
cmaru=match.count("○")
cnt=15-lmatch+cmaru

if cnt>=8:
    print("YES")
else:
    print("NO")

Failing test case input:
oxoxoyoxoxoxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
match=input()
match=list(match)
lmatch=len(match)
cmaru=match.count("o")

cnt=15-lmatch+cmaru


if cnt>=8:
    print("YES")
else:
    print("NO")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=input()
s=len(S)
ans=S.count("o")
print(ans)
if ans+(15-s)>=8:
    print("Yes")
if ans+(15-s)<8:
    print("No")

Failing test case input:
xoyoxoxoyoxoxo

Expected output:
YES


Actual output:
7
Yes


Fixed submission (verdict: Accepted):
S=input()
s=len(S)
ans=S.count("o")
if ans+(15-s)>=8:
    print("YES")
if ans+(15-s)<8:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

s = input()
a = 0

for i in s:
    a += 1 if i == 'o' else 0

if a >= 8:
    print('YES')
else:
    print('NO')


Failing test case input:
owoxowyoowoxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):

s = input()
a = 0

for i in s:
    a += 1 if i == 'o' else 0

if a + 15 - len(s) >= 8:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

if __name__ == '__main__':
    s=input()
    count=0
    for i in s:
        if i=="o":
            count+=1
    if 15- len(s) >=8-count:
        print("Yes")
    else:
        print("No")

Failing test case input:
owowoxooowxxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
if __name__ == '__main__':
    s=input()
    count=0
    for i in s:
        if i=="o":
            count+=1
    if 15- len(s) >=8-count:
        print("YES")
    else:
        print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
cnt=0
for i in range(len(s)):
  if s[i] == 'o':
    cnt+=1
print("YES" if cnt >= 8 else "NO")

Failing test case input:
owzxowoooxoxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=input()
cnt=0
for i in range(len(s)):
  if s[i] == 'o':
    cnt+=1
print("YES" if cnt >= 8-(15-len(s)) else "NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = list(input())
K = len(S)
L = S.count("x")

print("Yes" if -L + 15 >= 8 else "No")

Failing test case input:
oxxowowoooxowy

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = list(input())
K, L = len(S), S.count("x")
print("YES" if -L + 15 >= 8 else "NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
def main():
    n=input()
    win = n.count('o')
    if win+15-len(n) >=8:
        print('YES')
    else:
        print('No')

if __name__=='__main__':
    main()

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
No


Fixed submission (verdict: Accepted):
def main():
    n=input()
    win = n.count('o')
    if win+15-len(n) >=8:
        print('YES')
    else:
        print('NO')

if __name__=='__main__':
    main()

Problem: p03024
Buggy submission (PyPy3 (2.4.0), verdict: Wrong Answer):
s = input()
if 15 - len(s) + s.count("o") < 8:
    print("No")
else:
    print("Yes")

Failing test case input:
oooyooyxoxxxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
if 15 - len(s) + s.count("o") < 8:
    print("NO")
else:
    print("YES")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
win = s.count('o')

if win + (15-len(s)) >= 8:
  print('Yes')
else:
  print('No')

Failing test case input:
oxoxoxoxoyoxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
win = s.count('o')

if win + (15-len(s)) >= 8:
  print('YES')
else:
  print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=input()

b=S.count('x')
print(b)
if((15-b)>=8):
    print("YES")
else:
    print("NO")


Failing test case input:
oyowowxooxoxox

Expected output:
YES


Actual output:
4
YES


Fixed submission (verdict: Accepted):
S=input()

b=S.count('x')

if((15-b)>=8):
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()

if 7 >= S.count('×'):
    print('YES')
else:
    print('NO')


Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
S = input()

if 7 < S.count('x'):
    print('NO')
else:
    print('YES')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()

num = 0
for i in range(len(s)):
    if s[i] == 'o':
        num += 1
        
if 7 <= len(s) - num:
    print("YES")
else:
    print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
s = input()

num = 0
for i in range(len(s)):
    if s[i] == 'o':
        num += 1
        
if 15 - len(s) >= 8 - num:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()

cnt = 0
for i in s:
    if (i == 'o'):
        cnt += 1
print('Yes' if len(s) - cnt <= 7 else 'No')


Failing test case input:
owxoowoxoozxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()

cnt = 0
for i in s:
    if (i == 'o'):
        cnt += 1
print('YES' if len(s) - cnt <= 7 else 'NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
k = len(s)
o = s.count('o')
if 15 - o  <= 15 - k:
  print('YES')
else:
  print ('NO')

Failing test case input:
xxxovooowoxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()
k = len(s)
o = s.count('o')
if 15 - k + o >= 8:
  print('YES')
else:
  print ('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()
c = S.count('o')
r = S.rfind('o')
d = 13 - r
if c+d > 7:
    print('YES')
else:
    print('NO')

Failing test case input:
oxxowooywoxowo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
S = input()
c = S.count('o')
if c+15-len(S) > 7:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

s = input()

if ｓ.count('x') <= 7:
  print('Yes')
else:
  print('No')


Failing test case input:
oywowooywoyowo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):

s = input()

if s.count('x') <= 7:
  print('YES')
else:
  print('NO')
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()
WinNum = S.count('o')

if(15-len(S) >= (8-WinNum)):
    print("Yes")
else:
    print("No")



Failing test case input:
xwyoxooxooyxoo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = input()
WinNum = S.count('o')


if(15-len(S) >= (8-WinNum)):
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import math

n = list(map(str, input().split()))
n=n[0]

yes=0
no=0


if(no>=8):
  print("NO")
else:
  print("YES")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
import math

n = list(map(str, input().split()))
n=n[0]

yes=0
no=0

for i in range(len(n)):
  if(n[i]=='x'):
    no+=1
    
if(no>=8):
  print("NO")
else:
  print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
if s.count("o")<8:
    print("NO")
else:
    print("YES")


Failing test case input:
ooxoxoxxxoyoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=input()
if s.count("o")<8-(15-len(s)):
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import math

n = list(map(str, input().split()))
n=n[0]

yes=0
no=0


print(yes,no)
if(no>=8):
  print("NO")
else:
  print("YES")

Failing test case input:
owoxowzoowoxox

Expected output:
YES


Actual output:
0 0
YES


Fixed submission (verdict: Accepted):
import math

n = list(map(str, input().split()))
n=n[0]

yes=0
no=0

for i in range(len(n)):
  if(n[i]=='x'):
    no+=1
    
if(no>=8):
  print("NO")
else:
  print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=list(input())

maru = 0
for i in range(len(s)):
  if s[i] == "o":
    maru = maru + 1
if maru >= 8:
  print("YES")
else:
  print("NO")

Failing test case input:
xoxowooywoxowo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=list(input())

maru = 0
batu = 0
for i in range(len(s)):
  if s[i] == "o":
    maru = maru + 1
  else:
    batu = batu + 1
if 15 - maru - batu >= 8 - maru:
  print("YES")
else:
  print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()

sum_maru = sum([1 for c in S if c == 'x'])
if sum_maru >= 8:
    print("No")
else:
    print("Yes")

Failing test case input:
oxxowooywoyowo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = input()

sum_maru = sum([1 for c in S if c == 'x'])
if sum_maru >= 8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = list(str(input()))

if S.count("o") >= 8:
  print("Yes")
else:
  if 15 - len(S) + S.count("o") >= 8:
    print("Yes")
  else:
    print("No")

Failing test case input:
owoxowooowxxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = list(str(input()))

if S.count("o") >= 8:
  print("YES")
else:
  if 15 - len(S) + S.count("o") >= 8:
    print("YES")
  else:
    print("NO")
Problem: p03024
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
S = input()

xCount = 0
for s in S:
    if s == "x":
        xCount += 1

if xCount >= 8:
    print("No")
else:
    print("Yes")

Failing test case input:
oxoxowoxoxoxox

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = input()

xCount = 0
for s in S:
    if s == "x":
        xCount += 1

if xCount >= 8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
k = len(s)

count = 0
for i in s:
    if i == 'o':
        count += 1

if count + 15 - k >= 8:
    print('Yes')
else:
    print('No')


Failing test case input:
xwooxooyoyyxoo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
k = len(s)

count = 0
for i in s:
    if i == 'o':
        count += 1

if count + 15 - k >= 8:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()


w = 0
l = 0
for s in S:
    if s == 'o':
        w+=1
    else:
        l+=1

if (15 - len(S) + w >=8):
    print('YES')
else:
    print('No')


Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
No


Fixed submission (verdict: Accepted):
S = input()


w = 0
l = 0
for s in S:
    if s == 'o':
        w+=1
    else:
        l+=1

if (15 - len(S) + w >=8):
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = list(input())
win = S.count("o")
korekara = 15 -win
match = len(S)
nokori = 15 - match
if win - (nokori - korekara) >=8:
    print("YES")
else:
    print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
S = list(input())


win = S.count("o")

korekara = 8 - win

match = len(S)

nokori = 15 - match

if korekara <= 0:
    print("YES")
elif nokori >= korekara:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):

S = input()


Maru = int(S.count('o'))
Batsu = int(S.count('x'))
Nokori = 15 - Maru - Batsu


if Nokori + Maru >= 8:
	print("Yes")
else:
	print("NO")

Failing test case input:
xoxoxoxoxoxoxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):

S = input()


Batsu = int(S.count('x'))
Nokori = 15 - Batsu


if Batsu >= 8:
	print("NO")
else:
	print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = list(input())
win = S.count("o")
korekara = 15 -win
match = len(S)
nokori = 15 - match
if nokori >= korekara:
    print("YES")
else:
    print("NO")

Failing test case input:
xoxxwooowowowo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
S = list(input())


win = S.count("o")

korekara = 8 - win

match = len(S)

nokori = 15 - match

if korekara <= 0:
    print("YES")
elif nokori >= korekara:
    print("YES")
else:
    print("NO")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
cnt = 0
for i in range(len(s)):
    if s[0] == "o":
        cnt += 1
if cnt >= 8:
    print("YES")
else:
    print("NO")

Failing test case input:
xoooyoxxxoxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()
cnt = 0
for i in range(len(s)):
    if s[i] == "x":
        cnt += 1
if cnt >= 8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = list(input())
c=0
for i in S:
    if i=='o':
        c+=1
if 15-len(S)+c>=7:
    print("YES")
else:
    print("NO")


Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
S = list(input())
c=0
for i in S:
    if i=='o':
        c+=1
if 15-len(S)+c>=8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
string = input()
for i in string:
    sum_of_win = 1
    if i == 'o':
        sum_of_win += 1
    if i == 'x':
        sum_of_win -= 1
if sum_of_win >= 0:
    print("YES")
else:
    print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
string = input()
sum_of_o = 0
for i in string:
    if i == 'o':
        sum_of_o += 1
 
if 15-len(string) >= 8 - sum_of_o:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = list(input())
win= lose = 0
for i in s:
    if i =='o':
        win += 1
    else:
        lose += 1
if win >= 8:
    print("YES")
else:
    print("NO")

Failing test case input:
oxoxoxoxowoxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = list(input())
win= lose = 0
for i in s:
    if i =='o':
        win += 1
    else:
        lose += 1
l = 15 - len(s)
if l < 15:
    win += l
if win >= 8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()


print('YES' if 15 - sum(s=='x' for s in S) <= 7 else 'NO')

Failing test case input:
xxxovooowoxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
S = input()


print('YES' if 15 - sum(s=='x' for s in S) >= 8 else 'NO')

Problem: p03024
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
s=input()
if s.count("x") >= 8:
    print("No")
else:
    print("Yes")

Failing test case input:
xoxowooxwoxoxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s=input()
if s.count("x") >= 8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
k = len(s)
o = s.count('o')
if 8 - o + 15 - k <=  0:
  print('YES')
else:
  print ('NO')

Failing test case input:
owoxowyoowoxxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()
k = len(s)
o = s.count('o')
if 15 - k + o >= 8:
  print('YES')
else:
  print ('NO')
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
print("YNeos"[input().count("x")>=8::2])

Failing test case input:
xoxzxooowoxowo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
print("YNEOS"[input().count("x")>=8::2])

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
N = input()
num = 0
for i in N:
    if i == 'x':
        num += 1
if num >= 8:
    print('No')
else:
    print('Yes')

Failing test case input:
xoyoxoooyxxoxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
N = input()
num = 0
for i in N:
    if i == 'x':
        num += 1
if num >= 8:
    print('NO')
else:
    print('YES')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
X= input('')
Y=0
Z=0
for i in range(len(X)):
    c = X[i]
    if c == "o" :
        Y += 1
    elif c == 'x' :
        Z += 1
if Z >= 8 :
    print("NO")
elif Y >= 8 :
    print("YES")

Failing test case input:
oxxowooywoxowo

Expected output:
YES


Actual output:

Fixed submission (verdict: Accepted):
X= input('')
Y=0
Z=0
for i in range(len(X)):
    c = X[i]
    if c == "o" :
        Y += 1
    elif c == 'x' :
        Z += 1
if Z >= 8 :
    print("NO")
else :
    print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=input()
a=S.count('○')
b=S.count('✕')

if((15-b+a)>=8):
    print("Yes")
else:
    print("No")


Failing test case input:
oxxowoozwoyowo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S=input()

b=S.count('x')

if((15-b)>=8):
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import itertools as it
import collections as col
import heapq
import sys
sys.setrecursionlimit(10**9)
S=list(input())
T=[c for c in S if c == 'o']
print("YES" if len(T) + (15 - len(S)) >= 8 else "No")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
No


Fixed submission (verdict: Accepted):
import itertools as it
import collections as col
import heapq
import sys
sys.setrecursionlimit(10**9)


S=list(input())
T=[c for c in S if c == 'o']
print("YES" if len(T) + (15 - len(S)) >= 8 else "NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=input()
match=list(S)
lmatch=len(match)
cmaru=match.count("○")
cnt=15-lmatch+cmaru

if cnt>=8:
    print("YES")
else:
    print("NO")

Failing test case input:
oxxowooyvoxowo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
match=input()
match=list(match)
lmatch=len(match)
cmaru=match.count("o")

cnt=15-lmatch+cmaru


if cnt>=8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()

if S.count("x") > 7:
    print('NO')
else:
    print('Yes')

Failing test case input:
xoxoxooowoxzwo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = input()

if S.count("x") > 7:
    print('NO')
else:
    print('YES')
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
n = len(s)
s += "o"*(15-n)
if s.count("o"):
  print("YES")
else:
  print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
s = input()
n = len(s)
s += "o"*(15-n)
if s.count("o") >= 8:
  print("YES")
else:
  print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
cnt = 0
for i in range(len(s)):
    if s[0] == "o":
        cnt += 1
if cnt >= 7:
    print("YES")
else:
    print("NO")


Failing test case input:
xoyoxoxoyoxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()
cnt = 0
for i in range(len(s)):
    if s[i] == "x":
        cnt += 1
if cnt >= 8:
    print("NO")
else:
    print("YES")

Problem: p03024
Buggy submission (PyPy3 (2.4.0), verdict: Wrong Answer):
s=input()
makeban=0
for i in s:
    if i=="o":
        makeban+=1
if makeban<=7:
    print("YES")
else:
    print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
s=input()
makeban=0
for i in s:
    if i=="x":
        makeban+=1
if makeban<=7:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = input()
if c.count('x') <= 8:
  print("YES")
else:
  print("NO")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
c = input()
if c.count('x') <= 7:
  print("YES")
else:
  print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
 
win=0
lose=0
 
for c in s:
  if c == "o":
    win+=1
  else:
    lose+=1
 
if win + ( 15 - ( win + lose ) ) > 8:
  print("YES")
else:
  print("NO")

Failing test case input:
xoyoyoooyxxoxo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()

win = 0
lose = 0

for c in s:
    if c == "o":
        win += 1
    else:
        lose += 1

days = 15 - (win + lose)

if win + days >= 8:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S = input()
lS = list(S)

print('Yes') if lS.count('o') + 15 - len(lS) >= 8 else print('No')


Failing test case input:
oxwxoooooxoxxx

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
S = input()
lS = list(S)

print('NO') if lS.count('x') >= 8 else print('YES')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
inp = input()
maru = inp.count('o')
batu = inp.count('x')
inp_length = inp.__len__()
if maru > 7 or 15 - inp_length >= 8 - maru:
    print("Yes")
else:
    print("No")

Failing test case input:
xoooyoxxxoxoxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
inp = input()
maru = inp.count('o')
batu = inp.count('x')
inp_length = inp.__len__()
if maru > 7 or 15 - inp_length >= 8 - maru:
    print("YES")
else:
    print("NO")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a=input().count("x")
if a >= 8 :
    print("No")
else :
    print("Yes")

Failing test case input:
ywoxooowowoxxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
a=input().count("x")
if a >= 8 :
    print("NO")
else :
    print("YES")

Problem: p03024
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
s = input()
if s.count("x")>7:
  print("No")
else:
  print("Yes")

Failing test case input:
xxxoxooowoxoxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
if s.count("x")>7:
  print("NO")
else:
  print("YES")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = input()
cnt = s.count('x')
if cnt <= 7:
    print("Yes")
else:
    print("No")

Failing test case input:
ooxoxoxxxoyoxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
cnt = s.count('x')
if cnt <= 7:
    print("YES")
else:
    print("NO")

Problem: p03024
Buggy submission (PyPy3 (2.4.0), verdict: Wrong Answer):
s = input()
print('Yes' if s.count('o') + 15 - len(s) >= 8 else 'No')


Failing test case input:
ywoxooowowoxxo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = input()
print('YES' if s.count('o') + 15 - len(s) >= 8 else 'NO')

Problem: p03024
Buggy submission (PyPy3 (2.4.0), verdict: Wrong Answer):
s = input()
cnt = 0
for _s in s:
  if _s == "o":
    cnt += 1
if cnt >= 8:
  print("YES")
else:
  print("NO")

Failing test case input:
oxoxovoxoxoxox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s = input()
cnt = 0
for _s in s:
  if _s == "o":
    cnt += 1
if cnt + 15 - len(s) >= 8:
  print("YES")
else:
  print("NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = input()
if c.count('o') >= 8:
  print("NO")
else:
  print("YES")

Failing test case input:
xxxxxxxx

Expected output:
NO

Actual output:
YES


Fixed submission (verdict: Accepted):
c = input()
if c.count('x') <= 7:
  print("YES")
else:
  print("NO")

Problem: p03024
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
print("YES" if input().count("x") >= 8 else "NO")

Failing test case input:
oxoxoxoxoxowox

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
print("YES" if input().count("x") < 8 else "NO")

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
S=str(input())
N=S.count('o')
if N>=8:
    print('Yes')
else:
    print('No')

Failing test case input:
xxxoxooovoxoxo

Expected output:
YES


Actual output:
No


Fixed submission (verdict: Accepted):
S=str(input())
N=8-S.count('o')
n=15-len(S)
if n>=N:
    print('YES')
else:
    print('NO')

Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s=input()
print("YES" if s.count("o")>=8 else "NO")

Failing test case input:
owoxowyoowoxyo

Expected output:
YES


Actual output:
NO


Fixed submission (verdict: Accepted):
s=input()
print("NO" if s.count("x")>7 else "YES")
Problem: p03024
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
s = list(input())
cnt = s.count('o')
rest = 15 - len(s)
ans = 'Yes' if cnt + rest >= 8 else 'No'
print(ans)


Failing test case input:
xoxxxoooxowowo

Expected output:
YES


Actual output:
Yes


Fixed submission (verdict: Accepted):
s = list(input())
cnt = s.count('o')
rest = 15 - len(s)
ans = 'YES' if cnt + rest >= 8 else 'NO'
print(ans)
Problem: p02328
Buggy submission (Python3, verdict: Wrong Answer):
N = int(input())
*H, = map(int, input().split())
st = [(0, -1)]
ans = 0
for i in range(N):
    h = H[i]
    while h < st[-1][0]:
        h0, j = st.pop()
        ans = max(ans, (i-j)*h0)
    if st[-1][0] < h:
        st.append((h, i))
while st:
    h0, j = st.pop()
    ans = max(ans, (N-j)*h0)
print(ans)

Failing test case input:
8
3 6 4 9 4 4 0 4

Expected output:
20


Actual output:
18


Fixed submission (verdict: Accepted):
N = int(input())
*H, = map(int, input().split())
st = [(0, -1)]
ans = 0
for i in range(N):
    h = H[i]
    base = i
    while st and h <= st[-1][0]:
        h0, j = st.pop()
        ans = max(ans, (i-j)*h0)
        base = j
    st.append((h, base))
while st:
    h0, j = st.pop()
    ans = max(ans, (N-j)*h0)
print(ans)

Problem: p02328
Buggy submission (Python3, verdict: Wrong Answer):

N = int(input())
H = tuple(map(int, input().split()))

def calc(stack, i, h):
    tmp_max = 0
    while stack[-1][1] > h:
        pi, ph = stack.pop()
        tmp_max = max(tmp_max, (i-pi)*ph)
        if len(stack) == 0:
            break    
    if len(stack) == 0:
        stack.append([pi, h])
    elif stack[-1][1] < 0:
        stack.append([pi, h])
    
    return stack, tmp_max

stack = [] 
S_max = 0

for i, h in enumerate(H):
    if len(stack) == 0:
        stack.append([i, h])
    elif h > stack[-1][1]:
        stack.append([i, h])
    elif h == stack[-1][1]:
        pass
    else:
        stack, tmp_max = calc(stack, i, h)
        S_max = max(S_max, tmp_max)

stack, tmp_max = calc(stack, i+1, 0)
S_max = max(S_max, tmp_max)
print(S_max)

Failing test case input:
8
3 6 6 6 4 7 0 3

Expected output:
20


Actual output:
18


Fixed submission (verdict: Accepted):

N = int(input())
H = tuple(map(int, input().split()))

def calc(i, h):
    tmp_max = 0
    while stack[-1][1] > h:
        pi, ph = stack.pop()
        tmp_max = max(tmp_max, (i-pi)*ph)
        if len(stack) == 0:
            break
    if len(stack) == 0:
        stack.append([pi, h])
    elif stack[-1][1] < h:
        stack.append([pi, h])
    return tmp_max

stack = [] 
S_max = 0

for i, h in enumerate(H):
    if len(stack) == 0:
        stack.append([i, h])
    elif h > stack[-1][1]:
        stack.append([i, h])
    elif h == stack[-1][1]:
        pass
    else:
        tmp_max = calc(i, h)
        S_max = max(S_max, tmp_max)

tmp_max = calc(i+1, 0)
S_max = max(S_max, tmp_max)
print(S_max)
Problem: p02328
Buggy submission (Python3, verdict: Wrong Answer):
n = int(input())
rects = list(map(int, input().split()))
stack = []
ans = 0

for ind, rect in enumerate(rects):
  if not stack:
    stack.append((rect, ind))
  elif stack[-1][0] < rect:
    stack.append((rect, ind))
  elif stack[-1][0] == rect:
    continue
  else:
    while stack and stack[-1][0] > rect:
      prect, pind = stack.pop()
      ans = max(ans, prect * (ind - pind))
    if not stack or stack[-1][0] != rect:
      stack.append((rect, ind))

print(ans)


Failing test case input:
8
2 6 3 5 4 7 0 4

Expected output:
15


Actual output:
12


Fixed submission (verdict: Accepted):
n = int(input())
rects = list(map(int, input().split()))
rects.append(-1)
stack = []
ans = 0

for ind, rect in enumerate(rects):

  if not stack:
    stack.append((rect, ind))
  elif stack[-1][0] < rect:
    stack.append((rect, ind))
  elif stack[-1][0] == rect:
    continue
  else:
    while stack and stack[-1][0] > rect:
      prect, pind = stack.pop()
      ans = max(ans, prect * (ind - pind))
    stack.append((rect, pind))


print(ans)

Problem: p02328
Buggy submission (Python3, verdict: Wrong Answer):
n = int(input())
hs = list(map(int, input().split()))
stack = []
ans = 0

for i, h in enumerate(hs):
    while stack and stack[-1][1] > h:
        j, h2 = stack.pop()
        ans = max(ans, (i - j) * h2)
    if not stack or stack[-1][1] < h:
        stack.append((i, h))
ans = max(ans, max((n - j) * h2 for j, h2 in stack))

print(ans)

Failing test case input:
8
2 4 3 10 8 7 0 4

Expected output:
21


Actual output:
12


Fixed submission (verdict: Accepted):
n = int(input())
hs = list(map(int, input().split()))
stack = []
ans = 0

for i, h in enumerate(hs):
    j = -1
    while stack and stack[-1][1] > h:
        j, h2 = stack.pop()
        ans = max(ans, (i - j) * h2)
    if not stack or stack[-1][1] < h:
        stack.append((i if j == -1 else j, h))
ans = max(ans, max((n - j) * h2 for j, h2 in stack))

print(ans)
Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
go = 1
while go == 1:
    a = str(input())
    alist = list(a)
    print("alist[0] =", alist[0])
    if a == "0":
        go = 0
        exit
    sum = 0
    for i in alist:
        i = int(i)
        sum += i
    if go == 1:
        print(sum)


Failing test case input:
123
82
1000
0

Expected output:
6
10
1


Actual output:
alist[0] = 1
6
alist[0] = 8
10
alist[0] = 1
1
alist[0] = 0


Fixed submission (verdict: Accepted):
go = 1
while go == 1:
    a = str(input())
    alist = list(a)
    if a == "0":
        go = 0
        exit
    sum = 0
    for i in alist:
        i = int(i)
        sum += i
    if go == 1:
        print(sum)

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x = input()
    if x == "0":
        break
    num = [int(i) for i in x.split()]
    print(sum(num))

Failing test case input:
123
160
1110
0

Expected output:
6
7
3


Actual output:
123
160
1110


Fixed submission (verdict: Accepted):
while True:
    x = input()
    if x == "0":
        break
    num = [int(i) for i in x]
    print(sum(num))

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)-1):
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(count)


Failing test case input:
123
0
1000
0

Expected output:
6


Actual output:
6
0
1


Fixed submission (verdict: Accepted):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    if int(l[i]) == 0:
        break
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(count)

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x = input()
    if x == "0":
        break
    num = [int(i) for i in x.split(" ")]
    print(sum(num))

Failing test case input:
123
44
1100
0

Expected output:
6
8
2


Actual output:
123
44
1100


Fixed submission (verdict: Accepted):
while True:
    x = input()
    if x == "0":
        break
    num = [int(i) for i in x]
    print(sum(num))

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
x = 1
L=[]
n= 0
s=0
while x is not 0:
    x = int(input())
    L.append(x)
N=1
L.remove(0)
for i in L:
    while i >N:

        N=10*N
        n =i%N
        s+=(n/N*10)
        i-=n
    print (int(s))
    s=0
    N = 1

Failing test case input:
123
69
1011
0

Expected output:
6
15
3


Actual output:
5
15
2


Fixed submission (verdict: Accepted):
x = 1
L=[]
n= 0
s=0
while x is not 0:
    x = int(input())
    L.append(x)
N=1
L.remove(0)
for i in L:
    while i >=N:

        N=10*N
        n =i%N
        s+=(n/N*10)
        i-=n
    print (int(s))
    s=0
    N = 1
Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
from sys import stdin
for line in stdin:
    if line == '0':
        break
    num = list(map(int, line.strip('\n')))
    print(sum(num))


Failing test case input:
123
559
1100
0

Expected output:
6
19
2


Actual output:
6
19
2
0


Fixed submission (verdict: Accepted):
from sys import stdin
for line in stdin:
    if line == '0\n':
        break
    num = list(map(int, line.strip('\n')))
    print(sum(num))

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    count = 0
    if l[i] == '0':
        break
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(int(count))


Failing test case input:
123
98
1111
0

Expected output:
6
17
4


Actual output:
6
17
4
0


Fixed submission (verdict: Accepted):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    if int(l[i]) == 0:
        break
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(count)

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x = input()
    if x == "0":break
    print(len(str(x)))


Failing test case input:
123
55
0001
0

Expected output:
6
10
1


Actual output:
3
2
4


Fixed submission (verdict: Accepted):
while True:
    x = input()
    if x == "0":break
    print(sum(list(map(int,x))))

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
while 1:
    s = input()
    if s == '0':
        break
    print(sum(int(n)) for n in s)

Failing test case input:
123
20
1010
0

Expected output:
6
2
2


Actual output:
<generator object <genexpr> at 0x7ff06a464c70>
<generator object <genexpr> at 0x7ff06a464c70>
<generator object <genexpr> at 0x7ff06a464c70>


Fixed submission (verdict: Accepted):
while 1:
    s = input()
    if s == '0':break
    print(sum(int(n) for n in s))

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
def main():

    while True:
        number_string = input()
        if number_string == '0': break
        print(list(number_string))
        print(sum(map(int, list(number_string))))
    
main()

Failing test case input:
123
69
1011
0

Expected output:
6
15
3


Actual output:
['1', '2', '3']
6
['6', '9']
15
['1', '0', '1', '1']
3


Fixed submission (verdict: Accepted):
def main():

    while True:
        number_string = input()
        if number_string == '0': break
        print(sum(map(int, list(number_string))))
    
main()

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    if l[i] == '0':
        break
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(count)


Failing test case input:
123
151
1111
0

Expected output:
6
7
4


Actual output:
6
7
4
0


Fixed submission (verdict: Accepted):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    if int(l[i]) == 0:
        break
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(count)
Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
list1 = []
result = 0
while True:
    x = str(input())
    if x == '0':
        break
    else:
        for i in x:
            result += int(i)
        list1.append(result)
            
for i in list1:
    print(i)

Failing test case input:
123
55
1101
0

Expected output:
6
10
3


Actual output:
6
16
19


Fixed submission (verdict: Accepted):
list1 = []
while True:
    x = str(input())
    if x == '0':
        break
    else:
        result=0
        for i in x:
            result += int(i)
        list1.append(result)
            
for i in list1:
    print(i)

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
import sys
from functools import reduce
for line in sys.stdin:
    if line == "0":
        break
    s = reduce(lambda a,b: int(a)+int(b), line.strip())
    print(s)

Failing test case input:
123
132
1101
0

Expected output:
6
6
3


Actual output:
6
6
3
0


Fixed submission (verdict: Accepted):
import sys
from functools import reduce
for line in sys.stdin:
    if int(line) == 0:
        break
    s = reduce(lambda a,b: int(a)+int(b), line.strip())
    print(s)

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
a=0

while True:
    z=str(input())
    for i in z:
        k=int(i)
        a+=k
    print(a)
    a=0
    if z == '0' :  
        break

Failing test case input:
123
69
1011
0

Expected output:
6
15
3


Actual output:
6
15
3
0


Fixed submission (verdict: Accepted):
a=0

while True:
    z=str(input())
    if z == '0' :
        break
    for i in z:
        k=int(i)
        a+=k
    print(a)
    a=0

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    try:
        print(sum([int(i) for i in input()]))
    except:
        break

Failing test case input:
123
17
1010
0

Expected output:
6
8
2


Actual output:
6
8
2
0


Fixed submission (verdict: Accepted):
while True:
    s=input()
    if s=="0":
        break
    print(sum([int(i) for i in s]))

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    if l[i] == '0':
        break
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(int(count))


Failing test case input:
123
559
1000
0

Expected output:
6
19
1


Actual output:
6
19
1
0


Fixed submission (verdict: Accepted):
import sys

l = []
for i in sys.stdin:
    l.append(i)

for i in range(0,len(l)):
    if int(l[i]) == 0:
        break
    count = 0
    for j in range(0,len(l[i])-1):
        count += int(l[i][j])
    print(count)

Problem: p02416
Buggy submission (Python3, verdict: Wrong Answer):
x=1
while x!=0:
    x=list(input())
    x=map(int,x)
    x=sum(x)
    print(x)

Failing test case input:
123
9
1001
0

Expected output:
6
9
2


Actual output:
6
9
2
0


Fixed submission (verdict: Accepted):
x=1
while True:
    x=list(input())
    x=map(int,x)
    x=sum(x)
    if x==0:
        break
    print(x)