Harryxun/testdata huggingface dataset:
Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
p = list(map(int,input().split()))
ans = 0
ps=[]

for i in p:
    ps.append(i)
    #print(ps)
    if min(ps)>=i:
        ans+=1
        
print(ans)


Fixed submission:
n = int(input())
p = list(map(int,input().split()))
ans = 0
ps=[]
p_min = p[0]
for i in p:
    if p_min>i:
        p_min=i
    
    if p_min>=i:
        ans+=1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
p = list(map(int,input().split()))
ans = 0


for i in range(n):
    if min(p[:i+1])>=p[i]:
        ans+=1
        
print(ans)

Fixed submission:
n = int(input())
p = list(map(int,input().split()))
ans = 0
ps=[]
p_min = p[0]
for i in p:
    if p_min>i:
        p_min=i
    
    if p_min>=i:
        ans+=1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
p = list(map(int,input().split()))
ans = 0
# for i in range(n):
#     count=0
#     for j in range(i+1):
#         if p[i]>p[j]:
#             break
#         else:
#             count+=1
#     if count==i+1:
#         ans+=1
# print(ans)

for i in range(n):
    l = p[:i+1]
    #print(min(l),p[i])
    if min(l)>=p[i]:
        ans+=1

print(ans)

Fixed submission:
n = int(input())
p = list(map(int,input().split()))
ans = 0
ps=[]
p_min = p[0]
for i in p:
    if p_min>i:
        p_min=i
    
    if p_min>=i:
        ans+=1
print(ans)

Buggy python submission (verdict: Time Limit Exceeded):
n = int(input())
p = list(map(int,input().split()))
ans = 0
for i in range(n):
    count=0
    for j in range(i+1):
        if p[i]>p[j]:
            break
        else:
            count+=1
    if count==i+1:
        ans+=1
print(ans)

Fixed submission:
n = int(input())
p = list(map(int,input().split()))
ans = 0
ps=[]
p_min = p[0]
for i in p:
    if p_min>i:
        p_min=i
    
    if p_min>=i:
        ans+=1
print(ans)
Buggy python submission (verdict: Runtime Error):
import sys

a,b,k = map(int,input().split())
a1 = k-a
if a1 >=1:
  a2=b-a1
  if a2 <=0:
    a2 = 0
  a1=0
else:
  a1=a-k
  a2=b
print(f'{a1} {a2}')

Fixed submission:
import sys

a,b,k = map(int,input().split())
a1 = k-a
if a1 >=1:
  a2=b-a1
  if a2 <=0:
    a2 = 0
  a1=0
else:
  a1=a-k
  a2=b
print(a1,a2)

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

a,b,k = map(int,input().split())
a1 = k-a
if a1 >=1:
  a2=b-a1
  a1=0
else:
  a1=a-k
  a2=b
print(f'{a1} {a2}')

Fixed submission:
import sys

a,b,k = map(int,input().split())
a1 = k-a
if a1 >=1:
  a2=b-a1
  if a2 <=0:
    a2 = 0
  a1=0
else:
  a1=a-k
  a2=b
print(a1,a2)
Buggy python submission (verdict: Runtime Error):
import math
def lcm(x, y):
    return (x * y) // math.gcd(x, y)

s,t = map(int,input().split())
print(lcm(s,t))

Fixed submission:
from fractions import gcd
def lcm(x, y):
    return (x * y) // gcd(x, y)

s,t = map(int,input().split())
print(lcm(s,t))
Buggy python submission (verdict: Runtime Error):
import sys
x = input()
x1 = list(x)
h = len(x)
x = int(x)

if x>2000:
  print('1')
  sys.exit()

a1 = int(x1[h-1])
a2 = int(x1[h-2])

if 0 < a1 < 5:
  c1 = 1
elif a1 == 0:
  c1 = 0
else:
  c1 = 2

c2 = a2*2
if int(x1[0])+int(x1[1]) < c1+c2:
  print('0')
else:
  print('1')

Fixed submission:
import sys
x = input()
x1 = list(x)
h = len(x)
x = int(x)

if x>2000:
  print('1')
  sys.exit()

a1 = int(x1[h-1])
a2 = int(x1[h-2])

if 0 < a1 <= 5:
  c1 = 1
elif a1 == 0:
  c1 = 0
else:
  c1 = 2

c2 = a2*2
#print(x1[0],x1[1])
if h>3:
  if 10*int(x1[0])+int(x1[1]) < c1+c2:
    print('0')
  else:
    print('1')
else:
  if int(x1[0]) < c1+c2:
    print('0')
  else:
    print('1')

Buggy python submission (verdict: Runtime Error):
import sys
x = input()
x1 = list(x)
h = len(x)
x = int(x)

if x>2000:
  print('1')
  sys.exit()

a1 = int(x1[h-1])
a2 = int(x1[h-2])

if 1<=a1<=5:
  c1 = 1
elif:
  c1 = 0
else:
  c1 = 2

c2 = a2*2
if int(x1[0])+int(x1[1]) < c1+c2:
  print('0')
else:
  print('1')

Fixed submission:
import sys
x = input()
x1 = list(x)
h = len(x)
x = int(x)

if x>2000:
  print('1')
  sys.exit()

a1 = int(x1[h-1])
a2 = int(x1[h-2])

if 0 < a1 <= 5:
  c1 = 1
elif a1 == 0:
  c1 = 0
else:
  c1 = 2

c2 = a2*2
#print(x1[0],x1[1])
if h>3:
  if 10*int(x1[0])+int(x1[1]) < c1+c2:
    print('0')
  else:
    print('1')
else:
  if int(x1[0]) < c1+c2:
    print('0')
  else:
    print('1')

Buggy python submission (verdict: Runtime Error):
import sys
x = input()
x1 = list(x)
h = len(x)
x = int(x)

if x>2000:
  print('1')
  sys.exit()

a1 = int(x1[h-1])
a2 = int(x1[h-2])

if a1<=5:
  c1 = 1
else:
  c1 = 2

c2 = a2*2
if int(x1[0])+int(x1[1]) < c1+c2:
  print('0')
else:
  print('1')

Fixed submission:
import sys
x = input()
x1 = list(x)
h = len(x)
x = int(x)

if x>2000:
  print('1')
  sys.exit()

a1 = int(x1[h-1])
a2 = int(x1[h-2])

if 0 < a1 <= 5:
  c1 = 1
elif a1 == 0:
  c1 = 0
else:
  c1 = 2

c2 = a2*2
#print(x1[0],x1[1])
if h>3:
  if 10*int(x1[0])+int(x1[1]) < c1+c2:
    print('0')
  else:
    print('1')
else:
  if int(x1[0]) < c1+c2:
    print('0')
  else:
    print('1')
Buggy python submission (verdict: Runtime Error):
N = int(input())
S = str(input())

if N%2==1:
    print('No')
    sys.exit()

S_1 = S[:N//2]

S_2 = S_1+S_1
if S == S_2:
    print("Yes")
else:
    print("No")


Fixed submission:
import sys
N = int(input())
S = str(input())

if N%2==1:
    print('No')
    sys.exit()

S_1 = S[:N//2]

S_2 = S_1+S_1
if S == S_2:
    print("Yes")
else:
    print("No")

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

if N%2==0:
    N = int(N)
else:
    print('No')
    sys.exit()
S_1 = S[:N//2]

S_2 = S_1+S_1
if S == S_2:
    print("Yes")
else:
    print("No")

Fixed submission:
import sys
N = int(input())
S = str(input())

if N%2==1:
    print('No')
    sys.exit()

S_1 = S[:N//2]

S_2 = S_1+S_1
if S == S_2:
    print("Yes")
else:
    print("No")
Buggy python submission (verdict: Runtime Error):
import math
import itertools

a,b=map(int,input().split())
X = [[int(i) for i in input().split()] for i in range(a)] 
#for i in range():
c = list(itertools.combinations(X, 2))


ans = 0

for i in range(len(c)):
  d = 0
  for j in range(b):
    d += (c[i][0][j]-c[i][1][j])**2
    if j == b-1:
      d = math.sqrt(d)
      if d.is_integer():
        ans = ans+1

print(ans)



Fixed submission:
a,b,c=map(int,input().split())
m = a*b
n = c
if m<=n:
  print(m)
  
else:
  print(n)
Buggy python submission (verdict: Runtime Error):
import math
import itertools

a,b=map(int,input().split())
X = [[int(i) for i in input().split()] for i in range(a)] 
#for i in range():
c = list(itertools.combinations(X, 2))


def get_distance(x1, y1, x2, y2):
    d = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
    return d

ans = 0
for i in range(len(c)):
  C_x1 = c[i][0][0]
  C_x2 = c[i][1][0]
  C_y1 = c[i][0][1]
  C_y2 = c[i][1][1]
  d = get_distance(C_x1,C_y1,C_x2,C_y2)
  if d.is_integer():
    ans = ans+1

print(ans)

Fixed submission:
import math
import itertools

a,b=map(int,input().split())
X = [[int(i) for i in input().split()] for i in range(a)] 
#for i in range():
c = list(itertools.combinations(X, 2))


ans = 0

for i in range(len(c)):
  d = 0
  for j in range(b):
    d += (c[i][0][j]-c[i][1][j])**2
    if j == b-1:
      d = math.sqrt(d)
      if d.is_integer():
        ans = ans+1

print(ans)

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

a,b=map(int,input().split())
X = [[int(i) for i in input().split()] for i in range(a)] 
#for i in range():
c = list(itertools.combinations(X, 2))


def get_distance(x1, y1, x2, y2):
    d = math.sqrt((x2 - x1) ** 2 + (y2 - y1) ** 2)
    return d

ans = 0
for i in range(len(c)):
  C_x1 = c[i][0][0]
  C_x2 = c[i][1][0]
  C_y1 = c[i][0][1]
  C_y2 = c[i][1][1]
  d = get_distance(C_x1,C_y1,C_x2,C_y2)
  if type(d):
    ans = ans+1

print(ans)



Fixed submission:
import math
import itertools

a,b=map(int,input().split())
X = [[int(i) for i in input().split()] for i in range(a)] 
#for i in range():
c = list(itertools.combinations(X, 2))


ans = 0

for i in range(len(c)):
  d = 0
  for j in range(b):
    d += (c[i][0][j]-c[i][1][j])**2
    if j == b-1:
      d = math.sqrt(d)
      if d.is_integer():
        ans = ans+1

print(ans)
Buggy python submission (verdict: Runtime Error):
import sys
INPUT = sys.stdin.readline
 
def SINGLE_INT(): 
    return int(INPUT())
def MULTIPLE_INT_LIST(): 
    return list(map(int, INPUT().split()))
def MULTIPLE_INT_MAP(): 
    return map(int, INPUT().split())
def SINGLE_STRING(): 
    return INPUT()
def MULTIPLE_STRING(): 
    return INPUT().split()

N, A, B , A_goal, B_goal = MULTIPLE_INT_MAP()
S = SINGLE_STRING()
 
def surpass():
    if '...' in S[B-2:B_goal+1]:
        return 'Yes'
	else:
        return 'No'
 
 
if '##' in S[A-1: A_goal+1] or '##' in S[B-1:B_goal+1]:
    print('No')

else:
    if A_goal < B_goal:
        print('Yes')
    else:
        print(surpass())

Fixed submission:
import sys
INPUT = sys.stdin.readline

def SINGLE_INT(): return int(INPUT())
def MULTIPLE_INT_LIST(): return list(map(int, INPUT().split()))
def MULTIPLE_INT_MAP(): return map(int, INPUT().split())
def SINGLE_STRING(): return INPUT()
def MULTIPLE_STRING(): return INPUT().split()

N, A, B , A_goal, B_goal = MULTIPLE_INT_MAP()
S = SINGLE_STRING()

def surpass():

    if '...' in S[B-2:B_goal+1]:
        return 'Yes'
    else:
        return 'No'


if '##' in S[A-1: A_goal+1] or '##' in S[B-1:B_goal+1]:
    print('No')

else:
    if A_goal < B_goal:
        print('Yes')
    else:
        print(surpass())
Buggy python submission (verdict: Runtime Error):
a = [[int(i) for i in input().split()] for i in range(N)]
menseki = a[0]*a[1]/2
print(menseki)

Fixed submission:
a = [int(i) for i in input().split()]
menseki = int(a[0]*a[1]/2)
print(menseki)
Buggy python submission (verdict: Runtime Error):
import sys
INPUT = sys.stdin.readline

def SINGLE_INT(): return int(INPUT())
def MULTIPLE_INT_LIST(): return list(map(int, INPUT().split()))
def MULTIPLE_INT_MAP(): return map(int, INPUT().split())
def SINGLE_STRING(): return INPUT()
def MULTIPLE_STRING(): return INPUT().split()

N = SINGLE_INT()

def is_integer_num(n):
    if isinstance(n, int):
        return True
    if isinstance(n, float):
        return n.is_integer()
    return False

if is_integer_num(N/2):
    print(N)
else:
    print(N*2)

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


S = [int(1) if x == '+' else int(-1) for x in S]

print(sum(S))

Buggy python submission (verdict: Runtime Error):
import sys
INPUT = sys.stdin.readline

def SINGLE_INT(): return int(INPUT())
def MULTIPLE_INT_LIST(): return list(map(int, INPUT().split()))
def MULTIPLE_INT_MAP(): return map(int, INPUT().split())
def SINGLE_STRING(): return INPUT()
def MULTIPLE_STRING(): return INPUT().split()

N = SINGLE_INT()

def is_integer_num(n):
    if isinstance(n, int):
        return True
    if isinstance(n, float):
        return n.is_integer()
    return False

if is_integer_num(N/2):
    print(N)
else:
    print(N*2)
    

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


S = [int(1) if x == '+' else int(-1) for x in S]

print(sum(S))
Buggy python submission (verdict: Runtime Error):
import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict
 
x,y = map(int,input().split())
 
for i in range(1, x+1):
    # 足の数
    f = 2 * i + 4 * (x - i)
    if f == y:
        print('Yes')
        sys.exit()
    elif i==x: 
    	print('No')


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

import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())#整数値　複数の入力
def S_MAP(): return map(str, input().split())#文字　複数の入力
def LIST(): return list(map(int, input().split()))#整数　複数の入力　配列
def S_LIST(): return list(map(str, input().split()))#文字　複数の入力　配列


x=S_LIST()


print(x.index("0")+1)

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

import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict


x=S_LIST()


print(x.index("0")+1)

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

import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())#整数値　複数の入力
def S_MAP(): return map(str, input().split())#文字　複数の入力
def LIST(): return list(map(int, input().split()))#整数　複数の入力　配列
def S_LIST(): return list(map(str, input().split()))#文字　複数の入力　配列


x=S_LIST()


print(x.index("0")+1)
Buggy python submission (verdict: Runtime Error):
import sys
import collections
import itertools
import numpy as np

n,m = map(int, input().split())
al = np.ones(n,dtype="int8")
H = list(map(int, input().split()))
AB=[]

for i in range(m):
    AB.append(tuple(map(int, input().split())))

for t in range(m):
    A = AB[t][0]
    B = AB[t][1]

    bou1 = H[A-1]
    bou2 = H[B-1]
    if bou1<bou2:
        al[B-1] = al[B-1]-1
    elif bou2<bou1:
        al[A-1] = al[a-1]-1
    else:
        al[A-1] = al[a-1]-1
        al[B-1] = al[B-1]-1
print(np.count_nonzero(al>0))

Fixed submission:
import sys
import collections
import itertools
import numpy as np

n,m = map(int, input().split())
al = np.ones(n,dtype="int8")
H = list(map(int, input().split()))
AB=[]

for i in range(m):
    AB.append(tuple(map(int, input().split())))

for t in range(m):
    A = AB[t][0]
    B = AB[t][1]
	
    bou1 = H[A-1]
    bou2 = H[B-1]
    if bou1<bou2:
        al[A-1] = al[A-1]-1
    elif bou2<bou1:
        al[B-1] = al[B-1]-1
    else:
        al[A-1] = al[A-1]-1
        al[B-1] = al[B-1]-1
print(np.count_nonzero(al==1))
Buggy python submission (verdict: Time Limit Exceeded):
import collections
N = int(input())
A = list(map(int, input().split()))

for i in range(1,N+1):
  print(A.count(i))

Fixed submission:
import collections
N = int(input())
A = list(map(int, input().split()))
count = collections.Counter(A)

for i in range(1,N+1):
  print(count[i])

Buggy python submission (verdict: Time Limit Exceeded):
import collections
N = int(input())
A = list(map(int, input().split()))
count = collections.Counter(A)

for i in range(1,N+1):
  print(A.count(i))

Fixed submission:
import collections
N = int(input())
A = list(map(int, input().split()))
count = collections.Counter(A)

for i in range(1,N+1):
  print(count[i])
Buggy python submission (verdict: Runtime Error):
import statistics
import sys
import math
INPUT = sys.stdin.readline
#入力関数
def SORO_INT(): return int(INPUT())
def MULT_INT_LIST(): return list(map(int, INPUT().split()))
def MULT_INT_MAP(): return map(int, INPUT().split())
def SORO_STRING(): return INPUT()
def MULT_STRING(): return INPUT().split()
 
def is_integer_num(n):
    if isinstance(n, int):
        return True
    if isinstance(n, float):
        return n.is_integer()
    return False
    
A = MULT_INT_LIST()
mean = statistics.mean(A)
 
if is_integer_num(mean):
  print(int(mean))
else:
  print('IMPOSSIBLE')
 
 
import statistics
import sys
import math
INPUT = sys.stdin.readline
#入力関数
def SORO_INT(): return int(INPUT())
def MULT_INT_LIST(): return list(map(int, INPUT().split()))
def MULT_INT_MAP(): return map(int, INPUT().split())
def SORO_STRING(): return INPUT()
def MULT_STRING(): return INPUT().split()

def is_integer_num(n):
    if isinstance(n, int):
        return True
    if isinstance(n, float):
        return n.is_integer()
    return False
    
A = MULT_INT_LIST()
mean = statistics.mean(A)

if is_integer_num(mean):
  print(int(mean))
else:
  print('IMPOSSIBLE')

Fixed submission:
import statistics
import sys
import math
INPUT = sys.stdin.readline
#入力関数
def SORO_INT(): return int(INPUT())
def MULT_INT_LIST(): return list(map(int, INPUT().split()))
def MULT_INT_MAP(): return map(int, INPUT().split())
def SORO_STRING(): return INPUT()
def MULT_STRING(): return INPUT().split()
 
def is_integer_num(n):
    if isinstance(n, int):
        return True
    if isinstance(n, float):
        return n.is_integer()
    return False
    
A = MULT_INT_LIST()
mean = statistics.mean(A)
 
if is_integer_num(mean):
  print(int(mean))
else:
  print('IMPOSSIBLE')
Buggy python submission (verdict: Runtime Error):
N=int(input())
test_case=[input() for _ in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+a)
print('WA x '+b)
print('TLE x '+c)
print('RE x '+d)


Fixed submission:
N=int(input())
test_case=[input() for _ in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+ str(a))
print('WA x '+ str(b))
print('TLE x '+str(c))
print('RE x '+str(d))

Buggy python submission (verdict: Runtime Error):
N=int(input())
test_case=[input() for_in range(N)]
a=test_case.count(''AC'')
b=test_case.count(''WA'')
c=test_case.count(''TLE'')
d=test_case.count(''RE'')
print('AC x '+a)
print('WA x '+b)
print('TLE x '+c)
print('RE x '+d)


Fixed submission:
N=int(input())
test_case=[input() for _ in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+ str(a))
print('WA x '+ str(b))
print('TLE x '+str(c))
print('RE x '+str(d))

Buggy python submission (verdict: Runtime Error):
N=int(input())
test_case=[input() for_in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+ a)
print('WA x '+ b)
print('TLE x '+ c)
print('RE x '+ d)


Fixed submission:
N=int(input())
test_case=[input() for _ in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+ str(a))
print('WA x '+ str(b))
print('TLE x '+str(c))
print('RE x '+str(d))

Buggy python submission (verdict: Runtime Error):
N=int(input())
test_case=[input() for_in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+a)
print('WA x '+b)
print('TLE x '+c)
print('RE x '+d)

Fixed submission:
N=int(input())
test_case=[input() for _ in range(N)]
a=test_case.count('AC')
b=test_case.count('WA')
c=test_case.count('TLE')
d=test_case.count('RE')
print('AC x '+ str(a))
print('WA x '+ str(b))
print('TLE x '+str(c))
print('RE x '+str(d))
Buggy python submission (verdict: Runtime Error):
from math import inf

n = int(input())
h = list(map(int, input().split()))

costs = [inf]*n
costs[0] = 0

for i in range(n):
	for j in (i+1, i+2):
		if j < n:
			costs[j] = min(costs[j], costs[i]+abs(h[i]-h[j]))
print(c[-1])

Fixed submission:
from math import inf

n = int(input())
h = list(map(int, input().split()))

costs = [inf]*n
costs[0] = 0

for i in range(n):
	for j in (i+1, i+2):
		if j < n:
			costs[j] = min(costs[j], costs[i]+abs(h[i]-h[j]))
print(costs[-1])
Buggy python submission (verdict: Runtime Error):
if int(input())%1000==0:
    print(0)
else:
    print(1000-((int(input()))%1000))

Fixed submission:
n = int(input())
if n%1000==0:
    print(0)
else:
    print(1000-(n%1000))
Buggy python submission (verdict: Runtime Error):
a = int(imput)
print(a(1+a(1+a)))

Fixed submission:
a = int(input())
print(a+a**2+a**3)

Buggy python submission (verdict: Runtime Error):
a = int(input)
b = a**2
c = a**3
print(a+b+c)

Fixed submission:
a = int(input())
print(a+a**2+a**3)

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

print(a+a**2+a**3)

Fixed submission:
a = int(input())
print(a+a**2+a**3)
Buggy python submission (verdict: Runtime Error):
n=input()

if n%2==0:
    print(n/2)
else:
    print(n//2+1)

Fixed submission:
n=int(input())

if n%2==0:
    print(n//2)
else:
    print(n//2+1)
Buggy python submission (verdict: Runtime Error):
import math

a, b, x = map(int, input().split())

t = a*a*b

if x <= t*0.5:
    tan = 2*x/(a*b*b)
    theta = math.degrees(math.atan(tan))
else:
    tan = a*a*a/(2*(a*a*b - x))
    theta = math.degrees(math.atan(tan))

print(90 - theta)

Fixed submission:
import math

a, b, x = map(int, input().split())

t = a*a*b

if x == t:
    theta = 90
elif x <= t*0.5:
    tan = 2*x/(a*b*b)
    theta = math.degrees(math.atan(tan))
else:
    tan = a*a*a/(2*(a*a*b - x))
    theta = math.degrees(math.atan(tan))

print(90 - theta)
Buggy python submission (verdict: Runtime Error):
s = input()
k = int(input())

prev = ""
count = 0
flag = 0
for i in s:
    if flag == 1:
        prev = i
        flag = 0
        continue
    if prev == i:
        count += 1
        flag = 1
    prev = i

count2 = 0
if s[0] == s[-1] and s[-1] != s[-2]:
    count2 = 1
ret = count*k + count2*(k-1)

print(ret)

Fixed submission:
s = input()
k = int(input())

prev = ""
count1 = 0
count2 = 0
count3 = 0
flag = 0
for i in s:
    if flag == 1:
        prev = i
        flag = 0
        continue
    if prev == i:
        count1 += 1
        flag = 1
    prev = i



for i in s:
    if flag == 1:
        prev = i
        flag = 0
        continue
    if prev == i:
        count2 += 1
        flag = 1
    prev = i

for i in s:
    if flag == 1:
        prev = i
        flag = 0
        continue
    if prev == i:
        count3 += 1
        flag = 1
    prev = i

if k % 2 == 1:
    ret = count1 + (k-1) // 2 * (count2 + count3)
else:
    ret = count1 + ((k-1)//2+1) * count2 + (k-1)//2 * count3

print(ret)
Buggy python submission (verdict: Runtime Error):
if __name__ == "__main__":
  n = input()
  if n % 2 == 0:
    print(0.5)
  else:
    p = (n+1)/(2*n)
    print(p)

Fixed submission:
if __name__ == "__main__":
    n = int(input())
    if n % 2 == 0:
        print(0.5)
    else:
        p = (n + 1) / (2 * n)
        print(p)
Buggy python submission (verdict: Runtime Error):
x = int(input())
if x => 30:
  print("Yes")
else:
  print("No")
  


Fixed submission:
x = int(input())
if x >= 30:
  print("Yes")
else:
  print("No")

Buggy python submission (verdict: Runtime Error):
X = int(input())
if x >= 30:
  print("Yes")
else:
  print("No")
  


Fixed submission:
x = int(input())
if x >= 30:
  print("Yes")
else:
  print("No")

Buggy python submission (verdict: Runtime Error):
X = int(input())
if x => 30:
  print("Yes")
else:
  print("No")
  

Fixed submission:
x = int(input())
if x >= 30:
  print("Yes")
else:
  print("No")
Buggy python submission (verdict: Runtime Error):
k = int(input())
t = 7
kou = 1

if k % 2 != 0:
  if k % 5 != 0:
    while True:
      kou += 1
      t = 10 * t + 7
    
    if t % k == 0:
    print(kou)
    break

print(-1)


Fixed submission:
K = int(input())

if K % 2 == 0 or K % 5 == 0:
    print(-1)
    exit()

i = 0
ai = 0
while True:
    ai = (ai * 10 + 7) % K
    i += 1
    if ai == 0:
        break
print(i)

Buggy python submission (verdict: Time Limit Exceeded):
k = int(input())
t = 7
kou = 1

if k % 2 != 0:
  if k % 5 != 0:
    while t % k != 0:
      kou += 1
      t = 10 * t + 7
    
    print(kou)
    quit()

print(-1)

Fixed submission:
K = int(input())

if K % 2 == 0 or K % 5 == 0:
    print(-1)
    exit()

i = 0
ai = 0
while True:
    ai = (ai * 10 + 7) % K
    i += 1
    if ai == 0:
        break
print(i)

Buggy python submission (verdict: Time Limit Exceeded):
k = int(input())
t = 7
kou = 1

if k % 2 == 0:
  print(-1)
  quit()
  
while t % k != 0:
    kou += 1
    t = 10 * t + 7
    
print(kou)

Fixed submission:
K = int(input())

if K % 2 == 0 or K % 5 == 0:
    print(-1)
    exit()

i = 0
ai = 0
while True:
    ai = (ai * 10 + 7) % K
    i += 1
    if ai == 0:
        break
print(i)
Buggy python submission (verdict: Runtime Error):
t = input()
maxt = ""
if len(t) = 1:
  print("D")
else:
  while len(maxt) = len(t):
    if len(maxt) // 2 = 0:
      maxt += "P"
    else:
      maxt += "D"
  
  print(maxt)


Fixed submission:
t = input()
tt = t.replace("?", "D")
print(tt)

Buggy python submission (verdict: Runtime Error):
t = input()
lent = len(t)
maxt = ""
if lent = 1:
  print(D)
else:
  while len(maxt) = lent:
    if len(maxt) // 2 = 0:
      maxt + "P"
    else:
      maxt + "D"
  
  print(maxt)

Fixed submission:
t = input()
tt = t.replace("?", "D")
print(tt)