Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Runtime Error):
# ABC119B

n = int(input())

z = 0
for i in range(n):
    x, y = input().split()
    x = int(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)


Fixed submission:
# ABC119B

n = int(input())

z = 0
for i in range(n):
    x, y = input().split()
    x = float(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)

Buggy python submission (verdict: Runtime Error):
# ABC119B

n = int(input()

z = 0
for i in range(n):
    x, y = input().split()
    x = int(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)


Fixed submission:
# ABC119B

n = int(input())

z = 0
for i in range(n):
    x, y = input().split()
    x = float(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)

Buggy python submission (verdict: Runtime Error):
n = int(input()

z = 0
for i in range(len(xu)):
    x, y = input().split()
    x = int(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)


Fixed submission:
# ABC119B

n = int(input())

z = 0
for i in range(n):
    x, y = input().split()
    x = float(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)

Buggy python submission (verdict: Runtime Error):
 = int(input()

z = 0
for i in range(len(xu)):
    x, y = input().split()
    x = int(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)


Fixed submission:
# ABC119B

n = int(input())

z = 0
for i in range(n):
    x, y = input().split()
    x = float(x)
    if y == 'JPY':
        z += x
    else:
        z += x*380000
print(z)
Buggy python submission (verdict: Runtime Error):
　# ABC118A

a, b = map(int, input().split())
if b % a == 0:
    print(a+b)
else:
    print(b-a)


Fixed submission:
# ABC118A

a, b = map(int, input().split())
if b % a == 0:
    print(a+b)
else:
    print(b-a)
Buggy python submission (verdict: Runtime Error):
import numpy as np
n, m = map(int, input().split())
k = [0] * n
for i in range(n):
    k[i] = list(map(int, input().split()))
b = np.zeros((n, m))
for i in range(n):
    w = a[i]
    for j in range(len(w)):
        b[i, int(w[j])-1] = 1
print(sum(b.sum(axis=0) == n))


Fixed submission:
import numpy as np
n, m = map(int, input().split())
k = [0] * n
for i in range(n):
    k[i] = list(map(int, input().split()))

b = np.zeros((n, m))
for i in range(n):
    w = k[i]
    for j in range(1, len(w)):
        b[i, int(w[j])-1] = 1
print(sum(b.sum(axis=0) == n))
Buggy python submission (verdict: Runtime Error):
# ABC109B

n = int(input())
w = [int(input()) for i in range(n)]
ok = "Yes"
e = w[0][-1]
double = [w[0]]
for i in range(1, n):
    if double.count(w[i]) != 0:
        ok = "No"
        break
    double.append(w[i])
    s = w[i][0]
    if s != e:
        ok = "No"
        break
    e = w[i][-1]
print(ok)


Fixed submission:
n = int(input())
w = [input() for i in range(n)]
ok = "Yes"
e = w[0][-1]
double = [w[0]]
for i in range(1, n):
    if double.count(w[i]) != 0:
        ok = "No"
        break
    double.append(w[i])
    s = w[i][0]
    if s != e:
        ok = "No"
        break
    e = w[i][-1]
print(ok)
Buggy python submission (verdict: Runtime Error):
import numpy as np

def number_of_divisor(n):
	import numpy as np
	result = []
	while n > 1:
		div = divisor(n)
		result.append(div)
		n //= div
	index, result = np.unique(result, return_counts=True)
	return np.prod(result+1)

def divisor(n):
    if n % 2 == 0:
        return 2
    elif n % 3 == 0:
        return 3
    maxitr = intSqrt(n)
    i = 1
    while True:
        i += 4
        if i > maxitr:
            return n
        elif n % i == 0:
            return i
        i += 2
        if i > maxitr:
            return n
        elif n % i == 0:
            return i

def intSqrt(n):
    x = 1
    while True:
        x2 = (x + n // x) // 2
        if x2 ** 2 <= n and abs(x - x2) <= 1:
            break
        x = x2
    return x2

def ABC106B(n):
    count = 0
    for i in range(3, n+1, 2):
        if number_of_divisor(i) == 8:
            count += 1
    print(count)

n = int(input())
ABC106B(n)


Fixed submission:
import numpy as np

def unique(w):
    d = {}
    for c in w:
        if c in d.keys():
            d[c] += 1
        else:
            d.setdefault(c, 1)
    return list(d.keys()), list(d.values())

def number_of_divisor(n):
	import numpy as np
	result = []
	while n > 1:
		div = divisor(n)
		result.append(div)
		n //= div
	index, result = unique(result)
	result = [x + 1 for x in result]
	return np.prod(result)

def divisor(n):
    if n % 2 == 0:
        return 2
    elif n % 3 == 0:
        return 3
    maxitr = intSqrt(n)
    i = 1
    while True:
        i += 4
        if i > maxitr:
            return n
        elif n % i == 0:
            return i
        i += 2
        if i > maxitr:
            return n
        elif n % i == 0:
            return i

def intSqrt(n):
    x = 1
    while True:
        x2 = (x + n // x) // 2
        if x2 ** 2 <= n and abs(x - x2) <= 1:
            break
        x = x2
    return x2

def ABC106B(n):
    count = 0
    for i in range(3, n+1, 2):
        if number_of_divisor(i) == 8:
            count += 1
    print(count)

n = int(input())
ABC106B(n)
Buggy python submission (verdict: Runtime Error):
# ABC103A

import numpy as np

 = list(map(int, input().split()))
def task(b):
    return abs(b[1] - b[0]) + abs(b[2] - b[1])
a = np.array(a)
p = np.array([[1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2], [3,2,1]]) - 1
Min = np.inf
for i in range(6):
    Min = min(Min, task(a[p[i,:]]))
print(Min)


Fixed submission:
import numpy as np

a = list(map(int, input().split()))
def task(b):
    return abs(b[1] - b[0]) + abs(b[2] - b[1])
a = np.array(a)
p = np.array([[1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2], [3,2,1]]) - 1
Min = np.inf
for i in range(6):
    Min = min(Min, task(a[p[i,:]]))
print(Min)

Buggy python submission (verdict: Runtime Error):
import numpy as np

b = list(map(int, input().split()))
def task(b):
    return abs(b[1] - b[0]) + abs(b[2] - b[1])
a = np.array(a)
p = np.array([[1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2], [3,2,1]]) - 1
Min = np.inf
for i in range(6):
    Min = min(Min, task(a[p[i,:]]))
print(Min)


Fixed submission:
import numpy as np

a = list(map(int, input().split()))
def task(b):
    return abs(b[1] - b[0]) + abs(b[2] - b[1])
a = np.array(a)
p = np.array([[1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2], [3,2,1]]) - 1
Min = np.inf
for i in range(6):
    Min = min(Min, task(a[p[i,:]]))
print(Min)
Buggy python submission (verdict: Runtime Error):
import numpy as np
n = int(input())
a = [int(x) for x in input()]
print(np.amax(abs(np.subtract.outer(a, a))))


Fixed submission:
# ABC102B

import numpy as np
n = int(input())
a = [int(x) for x in input().split()]
print(np.amax(abs(np.subtract.outer(a, a))))

Buggy python submission (verdict: Runtime Error):
mport numpy as np
n = int(input())
a = [int(input()) for x in range(n)]
print(np.amax(abs(np.subtract.outer(a, a))))


Fixed submission:
# ABC102B

import numpy as np
n = int(input())
a = [int(x) for x in input().split()]
print(np.amax(abs(np.subtract.outer(a, a))))
Buggy python submission (verdict: Runtime Error):
n = int(input())
a = [int(x) for x in input().split()]

a2 = [a[i] - i - 1 for i in range(n)]
mean = sum(a2) / len(a2)
b = np.floor(mean)
a3 = sum([abs(a2[i] - b) for i in range(n)])
b = np.ceil(mean)
a4 = sum([abs(a2[i] - b) for i in range(n)])
print(int(min(a3, a4)))


Fixed submission:
import numpy as np

n = int(input())
a = [int(x) for x in input().split()]

a2 = [a[i] - i - 1 for i in range(n)]
mean = sum(a2) / len(a2)
median = np.median(np.array(a2))
b = np.floor(median)
a3 = sum([abs(a2[i] - b) for i in range(n)])
b = np.ceil(median)
a4 = sum([abs(a2[i] - b) for i in range(n)])
print(int(min(a3, a4)))
Buggy python submission (verdict: Runtime Error):
N = int(input())
S = input()
    cnt = 0
    for i in range(1, N):
        # スライスで部分文字列をつくって、set型に変換し、積集合で共通する英小文字を取得
        dup_cnt = set(S[:i]) & set(S[i:])
        # 共通する英小文字の数が現時点での最大値より大きいなら最大値を更新
        if cnt < len(dup_cnt):
            cnt = len(dup_cnt)
    print(cnt)


Fixed submission:
n = int(input())
s = input()
Max = 0
for i in range(1, len(s)): # i = 1
    length = len(set(s[:i]) & set(s[i:]))
    if length > Max:
        Max = length
print(Max)
Buggy python submission (verdict: Runtime Error):
import math
x = int(input())
res = 0
for b in range(1, int(math.sqrt(X))+1): # sqrt(X)付近まで探索
    for p in range(2, int(math.sqrt(X))+2): # sqrt(X)付近まで探索
        val = b**p
        if (val <= X) and (val > res): # X以下かつその値が最大値なら値を更新
            res = val
print(res)


Fixed submission:
import math
X = int(input())
res = 0
for b in range(1, int(math.sqrt(X))+1): # sqrt(X)付近まで探索
    for p in range(2, int(math.sqrt(X))+2): # sqrt(X)付近まで探索
        val = b**p
        if (val <= X) and (val > res): # X以下かつその値が最大値なら値を更新
            res = val
print(res)

Buggy python submission (verdict: Runtime Error):
x = int(input())
res = 0
for b in range(1, int(math.sqrt(X))+1): # sqrt(X)付近まで探索
    for p in range(2, int(math.sqrt(X))+2): # sqrt(X)付近まで探索
        val = b**p
        if (val <= X) and (val > res): # X以下かつその値が最大値なら値を更新
            res = val
print(res)


Fixed submission:
import math
X = int(input())
res = 0
for b in range(1, int(math.sqrt(X))+1): # sqrt(X)付近まで探索
    for p in range(2, int(math.sqrt(X))+2): # sqrt(X)付近まで探索
        val = b**p
        if (val <= X) and (val > res): # X以下かつその値が最大値なら値を更新
            res = val
print(res)
Buggy python submission (verdict: Runtime Error):
def f(a, b, c, k):
    abc = sorted([a, b, c])
    abc[2] *= 2 * k
    print(sum(abc))


f(map(int, input().split()), int(input()))


Fixed submission:
def f(a, b, c, k):
    abc = sorted([a, b, c])
    if k != 0:
        abc[2] *= 2 ** k
    print(sum(abc))

a, b, c = map(int, input().split())
k = int(input())
f(a, b, c, k)
Buggy python submission (verdict: Runtime Error):
n = int(input())
d, x = map(int, input().split())
a = [0] * n
for i in range(i):
    a[i] = int(input())
t = 0
for i in a:
    t += len([int(y) for y in range(1, d+1, i)])
print(x + t)

Fixed submission:
n = int(input())
d, x = map(int, input().split())
a = [0] * n
for i in range(n):
    a[i] = int(input())
t = 0
for i in a:
    t += len([int(y) for y in range(1, d+1, i)])
print(x + t)
Buggy python submission (verdict: Runtime Error):
# ABC091B

n = int(input)
s = [0] * n
for i in range(n):
    s[i] = input()
m = int(input)
t = [0] * m
for i in range(m):
    t[i] = input()

blue = {}
for c in s:
    if c in blue.keys():
        blue[c] += 1
    else:
        blue.setdefault(c, 1)
red = {}
for c in t:
    if c in red.keys():
        red[c] += 1
    else:
        red.setdefault(c, 1)

Max = 0
for blue_key, blue_value in blue.items():
    get = blue_value
    if blue_key in red.keys():
        for red_key, red_value in red.items():
            if blue_key == red_key:
                get -= red_value
                break
    Max = max(Max, get)
print(Max)


Fixed submission:
# ABC091B

n = int(input())
s = [0] * n
for i in range(n):
    s[i] = input()
m = int(input())
t = [0] * m
for i in range(m):
    t[i] = input()

blue = {}
for c in s:
    if c in blue.keys():
        blue[c] += 1
    else:
        blue.setdefault(c, 1)
red = {}
for c in t:
    if c in red.keys():
        red[c] += 1
    else:
        red.setdefault(c, 1)

Max = 0
for blue_key, blue_value in blue.items():
    get = blue_value
    if blue_key in red.keys():
        for red_key, red_value in red.items():
            if blue_key == red_key:
                get -= red_value
                break
    Max = max(Max, get)
print(Max)
Buggy python submission (verdict: Runtime Error):
# ABC089B

n = int(input())
s = list(map(int, input().split()))
if len(set(s)) == 4:
    print('Three')
else:
    print('Four')


Fixed submission:
n = int(input())
s = list(input().split())
if len(set(s)) == 3:
    print('Three')
else:
    print('Four')

Buggy python submission (verdict: Runtime Error):
# ABC089B

n = int(input())
s = list(map(int, input().split)))
if len(set(s)) == 4:
    print('Three')
else:
    print('Four')


Fixed submission:
n = int(input())
s = list(input().split())
if len(set(s)) == 3:
    print('Three')
else:
    print('Four')
Buggy python submission (verdict: Runtime Error):
# ABC085C

n, y = map(int, input().split())

for i in range(n+1):
    for j in range(n-i+1):
        k = n - i - j
        if k >= 0:
            if y == i*10000 + j*5000 + k*1000:
                print(i, j, k)
                return
print(-1, -1, -1)


Fixed submission:
def f(n, y):
    for i in range(n+1):
        for j in range(n-i+1):
            k = n - i - j
            if k >= 0:
                if y == i*10000 + j*5000 + k*1000:
                    print(i, j, k)
                    return
    print(-1, -1, -1)

n, y = map(int, input().split())
f(n, y)
Buggy python submission (verdict: Runtime Error):
n = int(input())
lr = [0] * n
for i in range(n):
    lr[i] = list(map(int, int().split()))
s = 0
for i, j in lr:
    s += j - i + 1
print(s)


Fixed submission:
n = int(input())
s = 0
for i in range(n):
    l, r = map(int, input().split())
    s += r - l +1
print(s)

Buggy python submission (verdict: Runtime Error):
n = int(input())
lr = [0] * n
for i in range(n):
    lr[i] = list(map(int, int().split()))
s = 0
for i in range(0, len(lr), 2):
    s += lr[i+1] - lr[i] + 1
print(s)


Fixed submission:
n = int(input())
s = 0
for i in range(n):
    l, r = map(int, input().split())
    s += r - l +1
print(s)
Buggy python submission (verdict: Runtime Error):
n, k = map(int, l.split())
l = list(map(int, l.split()))
l = sorted(l)
l = l[::-1]
print(sum(l[:k]))


Fixed submission:
n, k = map(int, input().split())
l = list(map(int, input().split()))
l = sorted(l)
l = l[::-1]
print(sum(l[:k]))
Buggy python submission (verdict: Time Limit Exceeded):
def f(n, p, a):
    if n == 1:
        if p == 0 and a[0] % 2 == 0:
            print(2)
        elif p == 0 and a[0] % 2 == 1:
            print(1)
        elif p == 1 and a[0] % 2 == 0:
            print(0)
        elif p == 1 and a[0] % 2 == 1:
            print(1)
    else:
        import itertools
        bin = list(itertools.product([0, 1], repeat=n))
        count = 0
        for i in bin:
            total = sum([a[j] for j in i if j == 1])
            if total % 2 == p:
                count += 1
        print(count)

n, p = map(int, input().split())
a = list(map(int, input().split()))
f(n, p, a)



Fixed submission:
# AGC017A

def f(n, p, a):
    odd = sum(i % 2 for i in a)
    if odd == 0:
        if p == 0:
            return 2**n
        elif p == 1:
            return 0
    else:
        return 2**(n-1)
        
n, p = map(int, input().split())
a = list(map(int, input().split()))
print(f(n, p, a))
Buggy python submission (verdict: Runtime Error):
n = int(input())
a = list(map(int, input().split()))
even = []
odd = []
for i in range(n):
    if i % 2:
        even.append(a[i])
    else:
        odd.append(a[i])
if n % 2 == 0:
    print(*even[::-1], *odd)
else:
    print(*odd[::-1], *even)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
even = []
odd = []
for i in range(n):
    if i % 2:
        even.append(a[i])
    else:
        odd.append(a[i])
if n % 2 == 0:
    print(*even[::-1], end=" ")
    print(*odd)
else:
    print(*odd[::-1], end=" ")
    print(*even)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = list(map(int, input().split()))
b = []
for i in range(n):
    b.append(a[i])
    b = b[::-1]
print(*b)


Fixed submission:
n = int(input())
a = list(map(int, input().split()))
even = []
odd = []
for i in range(n):
    if i % 2:
        even.append(a[i])
    else:
        odd.append(a[i])
if n % 2 == 0:
    print(*even[::-1], end=" ")
    print(*odd)
else:
    print(*odd[::-1], end=" ")
    print(*even)
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
a = [0] * n
b = [0] * n
for i in range(n):
    a[i], b[i] = map(int, input().split())

count = 0
for i in reversed(range(n)):
    c = b[i] * (-(-a[i] // b[i])) - a[i]
    for j in range(i):
        a[j] += c
    count += c
print(count)


Fixed submission:
n = int(input())
a = [0] * n
b = [0] * n
for i in range(n):
    a[i], b[i] = map(int, input().split())

count = 0
for i in reversed(range(n)):
    c = b[i] * (-(-a[i] // b[i])) - a[i]
    #for j in range(i):
    #    a[j] += c
    count += c
    if i >= 1:
        a[i-1] += count
print(count)
Buggy python submission (verdict: Time Limit Exceeded):
def ABC051B(k, s):
    count = 0
    for x in range(k+1):
        for y in range(k+1):
            for z in range(k+1):
                if x + y + z == s:
                    count += 1

    print(count)

k, s = map(int, input().split())
ABC051B(k, s)


Fixed submission:
def ABC051B(k, s):
    a = [0] * (3 * k + 1)
    mx = -(-3 * (k + 1) ** 2 // 4)
    for i in range(k + 1):
        a[i] = (i + 1) * (i + 2) // 2
        a[3 * k - i] = (i + 1) * (i + 2) // 2
    if k % 2 == 0:
        max_point = 3 * (k // 2)
        a[max_point] = mx
        odd_cum_diff = [x ** 2 for x in range(k // 2)]
        for j in range(k // 2):
            a[max_point - j] = mx - odd_cum_diff[j]
            a[max_point + j] = mx - odd_cum_diff[j]
    else:
        max_point = 3 * (k // 2) + 1
        a[max_point] = mx
        even_cum_diff = [x * (x + 1) for x in range(k // 2)]
        for j in range(k // 2):
            a[max_point - j] = mx - even_cum_diff[j]
            a[max_point + j + 1] = mx - even_cum_diff[j]
    # for i, v in enumerate(a):
    #     print(i, v)
    print(a[s])

k, s = map(int, input().split())
ABC051B(k, s)
Buggy python submission (verdict: Runtime Error):
# AGC008A

def func(x, y):
    if y >= x:
        if x >= 0:
            return y - x
        else:
            if y > 0:
                if abs(x) > abs(y):
                    return 1 - x - y
                else:
                    return 1 + x + y
            elif y <= 0:
                return y - x
    else:
        if x >= 0:
            if y < 0:
                if abs(x) > abs(y):
                    return 1 + x + y
                else:
                    return 1 - x - y
            elif y == 0 or y == 1:
                return x + 1
            else:
                if abs(x) > abs(y):
                    return 1 + x + y
                else:
                    return 1 + y - x
        else:
            return 2 + x - y

x, y = map(int, input().split())
print(f(x, y))


Fixed submission:
# AGC008A

def func(x, y):
    if y >= x:
        if x >= 0:
            return y - x
        else:
            if y > 0:
                if abs(x) > abs(y):
                    return 1 - x - y
                else:
                    return 1 + x + y
            elif y <= 0:
                return y - x
    else:
        if x >= 0:
            if y < 0:
                if abs(x) > abs(y):
                    return 1 + x + y
                else:
                    return 1 - x - y
            elif y == 0 or y == 1:
                return x + 1
            else:
                if abs(x) > abs(y):
                    return 1 + x + y
                else:
                    return 1 + y - x
        else:
            return 2 + x - y

x, y = map(int, input().split())
print(func(x, y))
Buggy python submission (verdict: Time Limit Exceeded):
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
print(len(x))


Fixed submission:
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
    n = len(x) // 2
    if ('T' not in x[:n]) and ('S' not in x[n:]):
        x = ''
        break
print(len(x))

Buggy python submission (verdict: Time Limit Exceeded):
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
print(len(x))


Fixed submission:
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
    n = len(x) // 2
    if ('T' not in x[:n]) and ('S' not in x[n:]):
        x = ''
        break
print(len(x))

Buggy python submission (verdict: Runtime Error):
# AGC005A

# TLE 2/13
x = input()
while 'ST' in x:
    x = x.replace('ST', '', 1)
print(len(x))


Fixed submission:
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
    n = len(x) // 2
    if ('T' not in x[:n]) and ('S' not in x[n:]):
        x = ''
        break
print(len(x))

Buggy python submission (verdict: Time Limit Exceeded):
# AGC005A

# TLE 2/13
x = input()
while 'ST' in x:
    x = x.replace('ST', '', 1)
print(len(x))


Fixed submission:
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
    n = len(x) // 2
    if ('T' not in x[:n]) and ('S' not in x[n:]):
        x = ''
        break
print(len(x))

Buggy python submission (verdict: Time Limit Exceeded):
# AGC005A

x = input()
while 'ST' in x:
    x = x.replace('ST', '', 1)
print(len(x))


Fixed submission:
x = input()
while 'ST' in x:
    x = x.replace('ST', '')
    n = len(x) // 2
    if ('T' not in x[:n]) and ('S' not in x[n:]):
        x = ''
        break
print(len(x))
Buggy python submission (verdict: Runtime Error):
a, b, h = map(int, input().split())
print((a+b)*h//2)

Fixed submission:
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Buggy python submission (verdict: Runtime Error):
a, b, h = map(int, input().split())
print((a + b) * h // 2)

Fixed submission:
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Buggy python submission (verdict: Runtime Error):
a, b, h = map(int, input().split())
print((a + b) * h // 2)

Fixed submission:
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)

Buggy python submission (verdict: Runtime Error):
a, b, h = map(int, input().split())
print((a + b) * h // 2)


Fixed submission:
a = int(input())
b = int(input())
h = int(input())
print((a + b) * h // 2)
Buggy python submission (verdict: Runtime Error):
import numpy as np
w = input()
index, count = np.unique(list(w), return_counts=True)
if all(count % 2 == 0):
    print('Yes')
else:
    print('No')

Fixed submission:
w = input()
# index, count = np.unique(list(w), return_counts=True)
d = {}
for c in w:
    if c in d.keys():
        d[c] += 1
    else:
        d.setdefault(c, 1)
for i, j in d.items():
    if j % 2 == 1:
        print('No')
        break
else:
    print('Yes')
Buggy python submission (verdict: Time Limit Exceeded):
a, b = map(int, input().split())
minus = 0
for i in range(a, b + 1):
    if i == 0:
        print('Zero')
        break
    elif i < 0:
        minus += 1
else:
    if minus % 2:
        print('Negative')
    else:
        print('Positive')


Fixed submission:
a, b = map(int, input().split())

if a * b <= 0:
    print('Zero')
elif 1 <= a:
    print('Positive')
else:
    if (b - a) %2 == 0:
        print('Negative')
    else:
        print('Positive')