Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Time Limit Exceeded):
from collections import deque, Counter


def bfs(start, graph):
    q = deque([(start, 0)])
    visited = set()

    while q:
        curr, dist = q.popleft()
        if curr not in visited:
            yield start, curr, dist
            visited.add(curr)
            for neighbor in graph[curr]:
                q.append((neighbor, dist + 1))


if __name__ == '__main__':
    n, x, y = tuple([int(i) for i in input().split()])
    graph = {i: [] for i in range(1, n + 1)}

    for i in range(1, n):
        graph[i].append(i + 1)
        graph[i + 1].append(i)
    graph[min(x, y)].append(max(x, y))
    graph[max(x, y)].append(min(x, y))

    dists = [0 for k in range(n)]
    distances = {}
    for i in range(1, n):
        for s, e, d in bfs(i, graph):
            if s != e:
                start = min(s, e)
                end = max(s, e)
                key = (start, end)
                if key in distances.keys():
                    distances[key] = min(distances[key], d)
                else:
                    distances[key] = d

    dists = Counter(distances.values())

    for k in range(1, n):
        print(dists[k] if k in dists.keys() else 0)


Fixed submission:
def distance(i, j, x, y):
    return min([abs(j - i), abs(x - i) + 1 + abs(j - y), abs(y - i) + 1 + abs(j - x)])


if __name__ == '__main__':
    n, x, y = tuple([int(i) for i in input().split()])
    x, y = min(x, y), max(x, y)

    dists = [0 for k in range(n)]
    for i in range(1, n):
        for j in range(i + 1, n + 1):
            d = distance(i, j, x, y)
            dists[d] += 1

    for k in dists[1:]:
        print(k)
Buggy python submission (verdict: Time Limit Exceeded):
from collections import defaultdict
from math import factorial

mem = {}


def num_combinations(_n, r):
    if _n < r:
        return 0
    elif _n in mem.keys():
        return mem[_n]
    mem[_n] = int(factorial(_n) / (factorial(r) * factorial(_n - r)))
    return mem[_n]


if __name__ == '__main__':
    n = int(input())
    xs = [int(s) for s in input().split()]
    freq = defaultdict(int)

    for n in xs:
        freq[n] += 1

    res = 0

    for k in range(len(xs)):
        res = 0
        for num in freq.keys():
            res += num_combinations(freq[num] - (1 if xs[k] == num else 0), 2)
        print(res)


Fixed submission:
from collections import defaultdict


def num_combinations(_n):
    return _n * (_n - 1) // 2


if __name__ == '__main__':
    n = int(input())
    xs = [int(s) for s in input().split()]
    freq = defaultdict(int)

    for n in xs:
        freq[n] += 1

    total = sum([num_combinations(n) for n in freq.values()])
    for x in xs:
        print(total - (freq[x] - 1))
Buggy python submission (verdict: Runtime Error):
from typing import List


def diff_one(l: List[str]) -> bool:
    prev = l[0]

    for i in range(1, len(l)):
        if abs(ord(l[i]) - ord(prev)) >= 2:
            return False
        prev = l[i]

    return True


def comb(current: List[str], rest: List[str], target: int):
    if len(current) == target:
        yield current
    elif len(current) < target and len(rest) > 0:
        for i in range(len(current) + 1):
            yield from comb(current + [rest[i]], rest, target)


if __name__ == '__main__':
    n = int(input())
    alphabet = [str(chr(i)) for i in range(97, 97 + 26)]

    for perm in comb([], alphabet[:n], n):
        if diff_one(perm):
            print("".join(perm))


Fixed submission:
def comb(current, mx, target: int):
    if len(current) == target:
        yield current
    elif len(current) < target and len(alphabet) > 0:
        for i in range(mx + 1):
            yield from comb(current + [chr(i + 97)], mx + 1 if i == mx else mx, target)


if __name__ == '__main__':
    n = int(input())
    alphabet = [str(chr(i)) for i in range(97, 97 + 26)]
    result = set()

    for perm in comb([], 0, n):
        print("".join(perm))

Buggy python submission (verdict: Runtime Error):
from typing import List


def diff_one(l: List[str]) -> bool:
    prev = l[0]

    for i in range(1, len(l)):
        if abs(ord(l[i]) - ord(prev)) >= 2:
            return False
        prev = l[i]

    return True


def comb(current: List[str], rest: List[str], target: int):
    if len(current) == target:
        yield current
    elif len(current) < target and len(rest) > 0:
        for i in range(len(current) + 1):
            yield from comb(current + [rest[i]], rest, target)


if __name__ == '__main__':
    n = int(input())
    alphabet = [str(chr(i)) for i in range(97, 97 + 26)]

    for perm in comb([], alphabet[:n], n):
        if diff_one(perm):
            print(perm)


Fixed submission:
def comb(current, mx, target: int):
    if len(current) == target:
        yield current
    elif len(current) < target and len(alphabet) > 0:
        for i in range(mx + 1):
            yield from comb(current + [chr(i + 97)], mx + 1 if i == mx else mx, target)


if __name__ == '__main__':
    n = int(input())
    alphabet = [str(chr(i)) for i in range(97, 97 + 26)]
    result = set()

    for perm in comb([], 0, n):
        print("".join(perm))
Buggy python submission (verdict: Time Limit Exceeded):
if __name__ == '__main__':
    n, a, b = tuple([int(s) for s in input().split()])
    res = 0

    while n > 0:
        res += min([a, n])
        n -= a
        n -= b

    print(res)


Fixed submission:
if __name__ == '__main__':
    n, a, b = tuple([int(s) for s in input().split()])
    div = n // (a + b)
    mod = n % (a + b)

    print(a * div + min([a, mod]))
Buggy python submission (verdict: Runtime Error):
if __name__ == '__main__':
    n, m = tuple([int(s) for s in input().split()])
    digits = [None] * m
    failed = False

    for i in range(m):
        si, ci = tuple([int(s) for s in input().split()])

        if si == 1 and ci == 0:
            print(-1)
            failed = True
            break

        if digits[si - 1] is not None and digits[si - 1] != ci:
            print(-1)
            failed = True
            break
        else:
            digits[si - 1] = ci

    if not failed:
        i = 0

        while digits[i] is None and len(digits[i:]) > n:
            i += 1

        if len(digits[i:]) > n:
            print(-1)
        else:
            digits = digits[i:]
            if digits[0] is None:
                digits[0] = 1
            for j in range(len(digits)):
                if digits[j] is None:
                    digits[j] = 0

            print("".join(["{}".format(d) for d in digits]))


Fixed submission:
if __name__ == '__main__':
    n, m = tuple([int(s) for s in input().split()])
    digits = [None] * 3
    failed = False

    for i in range(m):
        si, ci = tuple([int(s) for s in input().split()])

        if si > n:
            print(-1)
            failed = True
            break
        elif digits[n - si] is not None and digits[n - si] != ci:
            print(-1)
            failed = True
            break
        else:
            digits[n - si] = ci

    if not failed:
        if digits[-1] == 0 and n > 1:
            print(-1)
        else:
            digits = digits[:n]
            digits.reverse()
            if digits[0] is None and n > 1:
                digits[0] = 1
            for j in range(len(digits)):
                if digits[j] is None:
                    digits[j] = 0

            print("".join(["{}".format(d) for d in digits]))
Buggy python submission (verdict: Runtime Error):
a, b, c = map(int,input().split())

if a =< c =< b:
  print ("Yes")
else:
  print ("No")


Fixed submission:
a, b, c = map(int,input().split())
if (a <= c) and (b >= c):
  print ("Yes")
else:
  print ("No")

Buggy python submission (verdict: Runtime Error):
a, b, c = map(int,input().split())

if c >= a and c =< b:
  print ("Yes")
else:
  print ("No")


Fixed submission:
a, b, c = map(int,input().split())
if (a <= c) and (b >= c):
  print ("Yes")
else:
  print ("No")

Buggy python submission (verdict: Runtime Error):
a, b, c = map(int, input().split())

if c > A and c < B:
  print ("Yes")
else:
  print ("No")


Fixed submission:
a, b, c = map(int,input().split())
if (a <= c) and (b >= c):
  print ("Yes")
else:
  print ("No")
Buggy python submission (verdict: Runtime Error):
a , b = input().split()
if a+b >= 24:
	print ((a + b) - 24)
else:
  	print (a + b)

Fixed submission:
a , b = map(int, input().split())
if a+b >= 24:
	print ((a + b) - 24)
else:
  	print (a + b)

Buggy python submission (verdict: Runtime Error):
a , b = input().split()
if (a+b) >= 24:
	print (a + b - 24)
else:
  	print (a + b)


Fixed submission:
a , b = map(int, input().split())
if a+b >= 24:
	print ((a + b) - 24)
else:
  	print (a + b)

Buggy python submission (verdict: Runtime Error):
a , b = input().split()

if a + b > 24:
	print (a + b - 24)
else:
  	print (a + b)


Fixed submission:
a , b = map(int, input().split())
if a+b >= 24:
	print ((a + b) - 24)
else:
  	print (a + b)

Buggy python submission (verdict: Runtime Error):
a , b = (input().split())

if (a+b) > 24:
	print (a + b - 24)
else:
  	print (a + b)


Fixed submission:
a , b = map(int, input().split())
if a+b >= 24:
	print ((a + b) - 24)
else:
  	print (a + b)

Buggy python submission (verdict: Runtime Error):
a , b = int(input().split())

if (a+b) > 24:
	print (a + b - 24)
else:
  	print (a + b)

Fixed submission:
a , b = map(int, input().split())
if a+b >= 24:
	print ((a + b) - 24)
else:
  	print (a + b)
Buggy python submission (verdict: Runtime Error):
print("H" if input()==input() else "D")

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

if a==b:
	print ("H")
else:
  	print("D")

Buggy python submission (verdict: Runtime Error):
print("H" if input()==input() else "D")

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

if a==b:
	print ("H")
else:
  	print("D")

Buggy python submission (verdict: Runtime Error):
a = input()
b = input()

if a == b:
  print ("H")
else:
  print ("D")

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

if a==b:
	print ("H")
else:
  	print("D")
Buggy python submission (verdict: Runtime Error):
N = int(input())
x = N - ((N/15)200)

print (x)

Fixed submission:
n = int(input())
x = (n*800) - ((n//15)*200)
print (x)
Buggy python submission (verdict: Runtime Error):
a, x, b = input().split()
c = int(a)
d = int(b)
if x == ("+"):
  print (c + d)
elif op == ("-"):
  print (c - d)

Fixed submission:
a, x, b = input().split()
c = int(a)
d = int(b)
if x == ("+"):
  print (c + d)
elif x == ("-"):
  print (c - d)
Buggy python submission (verdict: Runtime Error):
c = raw_input()

if c == "a" :
  print ("vowel")
elif c == "e" :
  print ("vowel")
elif c == "i" :
  print ("vowel")
elif c == "o" :
  print ("vowel")
elif c == "u" :
  print ("vowel")
else:
  print ("consonant")


Fixed submission:
c = input()

if c == "a" :
  print ("vowel")
elif c == "e" :
  print ("vowel")
elif c == "i" :
  print ("vowel")
elif c == "o" :
  print ("vowel")
elif c == "u" :
  print ("vowel")
else:
  print ("consonant")

Buggy python submission (verdict: Runtime Error):
c = raw_input()

if c == "a" or "e" or "i" or "o" or "u":
  print ("vowel")
else:
  print ("consonant")


Fixed submission:
c = input()

if c == "a" :
  print ("vowel")
elif c == "e" :
  print ("vowel")
elif c == "i" :
  print ("vowel")
elif c == "o" :
  print ("vowel")
elif c == "u" :
  print ("vowel")
else:
  print ("consonant")

Buggy python submission (verdict: Runtime Error):
c = raw_input()

if c == a or e or i or o or u:
  print ("vowel")
else:
  print ("consonant")


Fixed submission:
c = input()

if c == "a" :
  print ("vowel")
elif c == "e" :
  print ("vowel")
elif c == "i" :
  print ("vowel")
elif c == "o" :
  print ("vowel")
elif c == "u" :
  print ("vowel")
else:
  print ("consonant")

Buggy python submission (verdict: Runtime Error):
c = raw_input()

if "c" == a or e or i or o or u:
  print ("vowel")
else:
  print ("consonant")

Fixed submission:
c = input()

if c == "a" :
  print ("vowel")
elif c == "e" :
  print ("vowel")
elif c == "i" :
  print ("vowel")
elif c == "o" :
  print ("vowel")
elif c == "u" :
  print ("vowel")
else:
  print ("consonant")
Buggy python submission (verdict: Runtime Error):
x = input()
y = input()
z = input()

print x[0]+y[0]+z[0]

Fixed submission:
x, y, z = input().split()

print (x[0]+y[0]+z[0])
Buggy python submission (verdict: Runtime Error):
x, y, z =  input().split()

if x + y + z = 17:
  print ("YES")
else:
  print ("NO")

Fixed submission:
x, y, z =  map(int, input().split())

if x + y + z == 17:
  print ("YES")
else:
  print ("NO")

Buggy python submission (verdict: Runtime Error):
x, y, z =  map(int, input().split())

if x + y + z = 17:
  print ("YES")
else:
  print ("NO")

Fixed submission:
x, y, z =  map(int, input().split())

if x + y + z == 17:
  print ("YES")
else:
  print ("NO")

Buggy python submission (verdict: Runtime Error):
number1 = raw_input ()
number2 = raw_input ()
number3 = raw_input ()
 
if number1 + number2 + number3 == 12:
    print ('YES')
if number1 + number2 + number3 != 12:
    print ('NO')

Fixed submission:
x, y, z =  map(int, input().split())

if x + y + z == 17:
  print ("YES")
else:
  print ("NO")

Buggy python submission (verdict: Runtime Error):
number1 = raw_input ()
number2 = raw_input ()
number3 = raw_input ()
 
if number1 + number2 + number3 == 12:
    print ('yes')
if number1 + number2 + number3 != 12:
    print ('no')

Fixed submission:
x, y, z =  map(int, input().split())

if x + y + z == 17:
  print ("YES")
else:
  print ("NO")

Buggy python submission (verdict: Runtime Error):
number1 = raw_input ()
number2 = raw_input ()
number3 = raw_input ()

if number1 + number2 + number3 == 12:
    print ('yes')
if number1 + number2 + number3 != 12:
    print ('no')

Fixed submission:
x, y, z =  map(int, input().split())

if x + y + z == 17:
  print ("YES")
else:
  print ("NO")
Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
S = {}
for i in range(N):
    s = input()
    if not(s[0] in S.keys()):
        S[s[0]] = [s]
    elif not(s in S[s[0]]):
        S[s[0]].append(s)

ans = 0
for i in S.values():
    ans += len(i)

print(ans)


Fixed submission:
from collections import Counter

N = int(input())
S = []
for i in range(N):
    S.append(input())

cnt = Counter(S)


print(len(cnt.keys()))

Buggy python submission (verdict: Time Limit Exceeded):
N = int(input())
S = []
for i in range(N):
    s = input()
    if not(s in S):
        S.append(s)

print(len(S))


Fixed submission:
from collections import Counter

N = int(input())
S = []
for i in range(N):
    S.append(input())

cnt = Counter(S)


print(len(cnt.keys()))
Buggy python submission (verdict: Runtime Error):
N,K = map(int, input().split())
print(min(N%K,abs(N%K-K)))


Fixed submission:
x,y,z = map(int, input().split())
print(z,x,y)
Buggy python submission (verdict: Runtime Error):
from math import gcd

A,B,C,D = map(int,input().split())

n_c = B//C - (A-1)//C
n_d = B//D - (A-1)//D
lcm_cd = C*D // gcd(C,D)
n_cd = B//lcm_cd - (A-1)//lcm_cd

print(B-A+1 - (n_c+n_d-n_cd))


Fixed submission:
A,B,C,D = map(int,input().split())

def gcd(a,b):
    while b:
        a,b = b,a%b
    return a

n_c = B//C - (A-1)//C
n_d = B//D - (A-1)//D
lcm_cd = C*D // gcd(C,D)
n_cd = B//lcm_cd - (A-1)//lcm_cd

print(B-A+1 - (n_c+n_d-n_cd))

Buggy python submission (verdict: Runtime Error):
import math

A,B,C,D = map(int,input().split())

n_c = B//C - (A-1)//C
n_d = B//D - (A-1)//D
lcm_cd = C*D // math.gcd(C,D)
n_cd = B//lcm_cd - (A-1)//lcm_cd

print(B-A+1 - (n_c+n_d-n_cd))


Fixed submission:
A,B,C,D = map(int,input().split())

def gcd(a,b):
    while b:
        a,b = b,a%b
    return a

n_c = B//C - (A-1)//C
n_d = B//D - (A-1)//D
lcm_cd = C*D // gcd(C,D)
n_cd = B//lcm_cd - (A-1)//lcm_cd

print(B-A+1 - (n_c+n_d-n_cd))

Buggy python submission (verdict: Runtime Error):
import math

A,B,C,D = map(int,input().split())

n_c = B//C - (A-1)//C
n_d = B//D - (A-1)//D
lcm_cd = C*D // math.gcd(C,D)
print(lcm_cd)
n_cd = B//lcm_cd - (A-1)//lcm_cd

print(B-A+1 - (n_c+n_d-n_cd))


Fixed submission:
A,B,C,D = map(int,input().split())

def gcd(a,b):
    while b:
        a,b = b,a%b
    return a

n_c = B//C - (A-1)//C
n_d = B//D - (A-1)//D
lcm_cd = C*D // gcd(C,D)
n_cd = B//lcm_cd - (A-1)//lcm_cd

print(B-A+1 - (n_c+n_d-n_cd))
Buggy python submission (verdict: Runtime Error):
n,k = map(int, input().split())
s = list(input())

s[k] = s[k-1].lower()

print("".join(s))

Fixed submission:
n,k = map(int, input().split())
s = list(input())

s[k-1] = s[k-1].lower()

print("".join(s))
Buggy python submission (verdict: Runtime Error):
th,ts,ah,ae=map(int,input().split())
while(th>0 && ah>0):
  ah=ah-ts
  if(ah<=0):
    break
  else:
    th=th-ae
if(th>0):
  print("Yes")
else:
  print("No")

Fixed submission:
th,ts,ah,ae=map(int,input().split())
while(th>0 and ah>0):
  ah=ah-ts
  if(ah<=0):
    break
  else:
    th=th-ae
if(th>0):
  print("Yes")
else:
  print("No")
Buggy python submission (verdict: Time Limit Exceeded):
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 19 21:27:49 2020

@author: arute
"""


from sys import stdin

import time
import numpy as np

############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])

data = []
write = stdin.readline().split()
for i in range(N-1):
    data.append(int(write[i]))

data = np.asarray(data)

out = ""
for i in range(N):
    out+=str((np.sum(data==(i+1))))+"\n"

print(out)

Fixed submission:
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 19 21:27:49 2020

@author: arute
"""


from sys import stdin

import time
import numpy as np


############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])

data = []
write = stdin.readline().split()
for i in range(N-1):
    data.append(int(write[i]))

data = np.asarray(data)

out = np.zeros(N)
for d in data:
    out[d-1] += 1

o = ""
for l in out:
    o+=str(int(l))+"\n"

print(o)

Buggy python submission (verdict: Time Limit Exceeded):
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 19 21:27:49 2020

@author: arute
"""


from sys import stdin

import time
import numpy as np

############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])

data = []
write = stdin.readline().split()
for i in range(N-1):
    data.append(int(write[i]))

data = np.asarray(data)

for i in range(N):
    print(np.sum(data==(i+1)))

Fixed submission:
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 19 21:27:49 2020

@author: arute
"""


from sys import stdin

import time
import numpy as np


############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])

data = []
write = stdin.readline().split()
for i in range(N-1):
    data.append(int(write[i]))

data = np.asarray(data)

out = np.zeros(N)
for d in data:
    out[d-1] += 1

o = ""
for l in out:
    o+=str(int(l))+"\n"

print(o)
Buggy python submission (verdict: Time Limit Exceeded):
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 19 21:27:49 2020

@author: arute
"""


from sys import stdin

import time
import numpy as np
import math



def combinations_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])
M = int(temp[1])

# すべての場合の数を計算。
probs = 0

for m in range(M,N+2):
    # 作れる最小は？
    small = sum(range(m))
    #
    large = sum(range(N+1-m,N+1))
    
    probs += large - small + 1
# 重複を計算し除去

print(probs)

Fixed submission:
# -*- coding: utf-8 -*-
"""
Created on Sun Apr 19 21:27:49 2020

@author: arute
"""


from sys import stdin

import time
import numpy as np
import math



def combinations_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])
M = int(temp[1])

# すべての場合の数を計算。
probs = np.zeros(1).astype("int64")

for i,m in enumerate(range(M,N+2)):
    # 作れる最小は？
    if i == 0:
        small = np.sum(np.arange(m))
        #
        large = np.sum(np.arange(N+1-m,N+1))
    else:
        small = (small+m-1).astype("int64")
        large = (large + (N+1-m)).astype("int64")
    probs = probs + (large - small + 1)

print(int(probs%(1e9+7)))
Buggy python submission (verdict: Time Limit Exceeded):
from sys import stdin

import time
import numpy as np
import math


############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])+1

out = 0
for i in range(1,N):
    for j in range(1,N):
        for k in range(1,N):
            part = math.gcd(j,k)
            out += math.gcd(part,i)
print(out)

Fixed submission:
# -*- coding: utf-8 -*-

from sys import stdin

import time
import numpy as np
import math

############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])+1

out = 0
for i in range(1,N):
    for j in range(1,N):
        part = np.gcd(j,i)
        #for k in range(1,N):       
        out += np.sum(np.gcd(part,np.arange(1,N)))
print(out)
Buggy python submission (verdict: Runtime Error):
from sys import stdin
import numpy as np


############################################

# read data for n sequences.
temp = stdin.readline().split()
N, M = np.asarray(temp).astype(int)
temp = stdin.readline().split()
a = np.asarray(temp).astype(int)

sumvotes = np.sum(a)

c = 0; OUT = False
for data in a:
    if data >= sumvotes/(4*M):
        c += 1
    if c >= M:
        OUT = True
        #break

if OUT:
    print("Yes")
else:
    print("No")

Fixed submission:
from sys import stdin
import numpy as np



############################################

# read data for n sequences.
temp = stdin.readline().split()
N, M = np.asarray(temp).astype(int)
temp = stdin.readline().split()
a = np.asarray(temp).astype(int)

sumvotes = np.sum(a)

c = 0; OUT = False
for data in a:
    if data >= sumvotes/(4*M):
        c += 1
    if c >= M:
        OUT = True
        #break

if OUT:
    print("Yes")
else:
    print("No")
Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-


from sys import stdin
import itertools


############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])
X = int(temp[1])

data = []
write = stdin.readline().split()
for i in range(N+1):
    data.append(int(write[i]))
    
count = 0
dis = 0

for d in data:
    if dis <= X:
        count += 1
        dis += d
    else:
        break

print(count)

Fixed submission:
# -*- coding: utf-8 -*-


from sys import stdin
import itertools



############################################

# read data for n sequences.
temp = stdin.readline().split()
N = int(temp[0])
X = int(temp[1])

data = []
write = stdin.readline().split()
for i in range(N):
    data.append(int(write[i]))
    
count = 1
dis = 0

for d in data:
    dis += d
    if dis <= X:
        count += 1
    else:
        break

print(count)
Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-


from sys import stdin



############################################


# read data for n sequences.
n = stdin.readline().split()
a = int(n[0])
b = int(n[1])
c = int(n[2])
#data = [int(stdin.readline().rstrip()) for _ in range(n)]

out = int(b / a)

if b > c and a < c:
    print("Yes")
else:
	print("No")


Fixed submission:
# -*- coding: utf-8 -*-


from sys import stdin



############################################


# read data for n sequences.
n = stdin.readline().split()
a = int(n[0])
b = int(n[1])
c = int(n[2])
#data = [int(stdin.readline().rstrip()) for _ in range(n)]

if b > c and a < c:
    print("Yes")
elif c < a and b < c:
	print("Yes")
else:
	print("No")