TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
antennas = [int(input()) for i in range(5)]

max_dist = int(input())

coords = {}

for i in range(len(antennas)):
  coords[i] = antennas[i]
flag = 1
for i in range():
  for j in range(i + 1, 5):
    if abs(coords[i] - coords[j]) > max_dist:
      print(':(')
      flag = 0
      break
  if flag == 0:
    break
if flag == 1:
  print('Yay!')
      

antennas = [int(input()) for i in range(5)]

max_dist = int(input())

coords = {}

for i in range(len(antennas)):
  coords[i] = antennas[i]
flag = 1
for i in range():
  for j in range(i + 1, 5):
    if abs(coords[i] - coords[j]) > max_dist:
      print(':(')
      flag = 0
      break
  if flag = 0:
    break
if flag = 1:
  print('Yay!')
      
  

antennas = [int(input()) for i in range(5)]

max_dist = int(input())

coords = {}

for i in range(len(antennas)):
  coords[i] = antennas[i]
flag = 1
for i in range(5):
  for j in range(i + 1, 5):
    if abs(coords[i] - coords[j]) > max_dist:
      print(':(')
      flag = 0
      break
  if flag == 0:
    break
if flag == 1:
  print('Yay!')
      

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
data = [int(input()) for i in range(5)]
K = input()
print(":(" if data[4]-data[0]>K else "Yay!" )

data = [input() in range(5)]
K = input()
print(":(" if data[4]-data[0]>K else "Yay!" )

data = [int(input()) for i in range(5)]
K = int(input())
print(":(" if data[4]-data[0]>K else "Yay!" )

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

x = [a,b,c,d,e]

x.sort()
if x[4] - x[0] > k:
    print("Yay!")
else:
    print(":(")


a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

x = [a,b,c,d,e]

x.sort()
if x[4] - x[0] <= k:
    print("Yay!")
else:
    print(":(")


Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
if b-a<=k and c-b<=k and d-c<=k and e-d<=K:
  print(":(")
else:
  print("Yay!")

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
if e-a<=k:
  print("Yay!")
else:
  print(":(")


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
A = [int(input()) for i in range(6)]
print('Yay!' if len(list(filter(lambda x: x >= A[-1], A))) == 0 else ':(')

A = [int(input()) for i in range(6)]
ans = 0
for i in A:
    ans += len(list(filter(lambda x: (i - x) > A[-1], A)))
print('Yay!' if ans == 0 else ':(')

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a,b,c,d,e = [int(input()) for i in range(5)]
k = int(input())
if a-e > k:
  print("Yay!")
else:
  print(":(")

a,b,c,d,e = [int(input()) for i in range(5)]
k = int(input())
if e-a > k:
  print("Yay!")
else:
  print(":(")

a,b,c,d,e = [int(input()) for i in range(5)]
k = int(input())
if a-e > k:
  print("Yay!")
else:
  print(":)")

a,b,c,d,e = [int(input()) for i in range(5)]
k = int(input())
if e-a > k:
  print(":(")
else:
  print("Yay!")

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
l=list(int(input()) for _ in range(5))
m=int(input())
cnt=0
for i in range(5):
  if l[i+1]-l[i]<=m:
    cnt+=1
print([":(","Yay!"][cnt==5])

a,*_,e,k=map(int,open(0))
print([":(","Yay!"][e-a<=k])


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
p = [a, b, c, d, e]

mi = [a%10,b%10,c%10,d%10,e%10]
mm = [i for i in mi if i != 0]
mm.sort()
sum = 0
for i in range(5):
	if p[i]%10 != 0:
		sum += (p[i]//10+1)*10
	else:
		sum += p[i]//10*10
if (mm):
	sum -= 10- mm[0]
else:
	sum = 0
print (sum)

a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
f = [a,b,c,d,e]

for i in range(5):
	for j in range(i+1,5):
		if abs(f[i]-f[j]) > k:
			print (":(")
			exit()
print ("Yay!")

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
from sys import stdin

def main():
    I = [int(input()) for _ in [0] * 6]

    if I[4] - I[0] >= I[5]:
        print(':(')
    else:
        print('Yah!')

input = lambda: stdin.readline().rstrip()
main()


from sys import stdin

def main():
    I = [int(input()) for _ in [0] * 6]

    if I[4] - I[0] > I[5]:
        print(':(')
    else:
        print('Yah!')

input = lambda: stdin.readline().rstrip()
main()


from sys import stdin

def main():
    I = [int(input()) for _ in [0] * 6]

    if I[4] - I[0] > I[5]:
        print(':(')
    else:
        print('Yay!')

input = lambda: stdin.readline().rstrip()
main()


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
frag = 0
max=a
min=a
if (max<b):
    max=b
if (max<c):
    max=c
if (max<d):
    max=d
if (max<e):
    max=e
if (min>b):
    min=b
if (min>c):
    min=c
if (min>d):
    min=d
if (min>e):
    min=e
z= max-min
if (z>k):
    print(':(')
    else :
        print('Yay!')

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
f=max([a,b,c,d,e])
g=min([a,b,c,d,e])
z= f-g
if (z>k):
    print(':(')
else :
    print('Yay!')

Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
v=map(int,open(0).read().split())
if v[5]>=v[4]-v[0]:
  print("Yay")
else:
  print(":(")

v=list(map(int,open(0).read().split()))
print(":("if v[5]<v[4]-v[0]else"Yay")

v=list(map(int,open(0).read().split()))
print(":("if v[5]<v[4]-v[0]else"Yay!")

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
if b - a <= k and c - b <= k and d - c <= k and e - d <= k and c - a <= k and d - a <= k and e - a <= k and d - b <= k and e - b <= k and e - c <= k:
    print("Yay!
")
else:
    print(": (")


a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
if b - a <= k and c - a <= k and d - a <= k and e - a <= k and c-b <= k and d-b <= k and e-b <= k and d-c <= k and e-c <= k and e - d <= k:
    print("Yay!")
else:
    print(":(")


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
#!/usr/bin/env python3



def solv(x, y, z, k, a, b, c):
    a = sorted(a, reverse=True)
    b = sorted(b, reverse=True)
    c = sorted(c, reverse=True)

    m = max(a[0] - a[-1], b[0] - b[-1], c[0] - c[-1])

    while True:
        aa = list(filter(lambda v: v > a[0] - m, a))
        bb = list(filter(lambda v: v > b[0] - m, b))
        cc = list(filter(lambda v: v > c[0] - m, c))

        if len(aa) * len(bb) * len(cc) < 10000:
            break

        m = m * 0.8

    aa = a
    bb = b
    cc = c

    all = []
    for ai in a:
        for bi in b:
            for ci in c:
                all.append(ai+bi+ci)

    all = sorted(all, reverse=True)

    return all[:k]


if __name__ == '__main__':

    x, y, z, k = map(int, input().split())
    a = map(int, input().split())
    b = map(int, input().split())
    c = map(int, input().split())

    ans = solv(x, y, z, k, a, b, c)

    for ans_i in ans:
        print(ans_i)


#!/usr/bin/env python3


def solv(a, b, c, d, e, k):
    ants = [a, b, c, d, e]
    for i in range(1, len(ants)):
        for j in range(i):
            if abs(ants[i] - ants[j]) > k:
                return ':('
    return 'Yay!'


if __name__ == '__main__':

    a = int(input())
    b = int(input())
    c = int(input())
    d = int(input())
    e = int(input())
    k = int(input())

    ans = solv(a, b, c, d, e, k)

    print(ans)


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
ae = [int(input()) for _ in range(5)]
ae.sort()
if ae[-1] - ae[0] <= int(Input()):
  print('Yay!')
else:
  print(':(')

ae = [int(input()) for _ in range(5)]
ae.sort()
if ae[-1] - ae[0] <= int(input()):
  print('Yay!')
else:
  print(':(')


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
d = [int(input()) for i in range(5)]
k = int(input())
ans = 'Yey!'
for i in d:
    for j in d:
        if abs(i-j)>k:
            ans = ':('
print(ans)


antenna = [int(input()) for i in range(5)]
k = int(input())
ans = 'Yey!'
for i in range(5):
    for j in range(i):
        if abs(antenna[i]-antenna[j])>k:
            ans = ':('
print(ans)

d = [int(input()) for i in range(5)]
k = int(input())
ans = 'Yay!'
for i in d:
    for j in d:
        if abs(i-j)>k:
            ans = ':('
print(ans)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
arr = []
for i in range(5):
  arr.append(int(input()))
k = int(input())
if k < max(arr) - min(arr):
  print('Yay!')
else:
  print(':(')

arr = []
for i in range(5):
  arr.append(int(input()))
k = int(input())
if k >= max(arr) - min(arr):
  print('Yay!')
else:
  print(':(')

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
num = []
n = int(input())
for i in range(5):
    num.append(int(input()))
a = min(num)
t = n // a
t += 4
if (n % a != 0):
    t += 5
else:
    
print(t)


num = []
n = int(input())
for i in range(5):
    num.append(int(input()))
a = min(num)
t = n // a
t += 4
print(t)


antenna = [int(input()) for i in range(5)]
k = int(input())

for i in antenna:
    antenna_out = list(filter(lambda j: (i - j) > k, antenna))
    if len(antenna_out) != 0:
        print(":(")
        break
else:
    print("Yay!")


Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
import numpy as np

dish_min = []
 
for i in range(5):
   dish_min.append(int(input()))
    
p = [i%10 for i in dish_min]
pp = [(i-1)%10 for i in dish_min]
x = np.argmin(pp)

for i in range(5):
  if i != x and p[i]:
  	dish_min[i] += (10 - p[i])

print(sum(dish_min))

import numpy as np

dish_min = []
 
for i in range(5):
   dish_min.append(int(input()))
    
p = [i%10 for i in dish_min]
pp = [(i-1)%10 for i in dish_min]
x = np.argmin(pp)

for i in range(5):
  if i != x and p[i]:
  	dish_min[i] += (10 - p[i])
print(dish_min)
print(sum(dish_min))

X, Y, Z, K = list(map(int, input().split(' ')))

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


A.sort()
A.reverse()
B.sort()
B.reverse()
C.sort()
C.reverse()

cal = []

def a(X,K):
  if X > K:
  	return K
  else:
    return X
  
for i in range(a(X,K-1000)):
  for j in range(a(Y,K-1000)):
    for k in range(a(Z,K-1000)):
      cal.append(A[i]+B[j]+C[k])

cal.sort()
cal.reverse()

for i in range(K):
  print(cal[i])


anntena_list = []
 
for i in range(5):
    anntena_list.append(int(input()))
    
m = int(input())
    
flag = False
for i in range(4):
  for j in range(3-i):
    if anntena_list[4-i] - anntena_list[j]  > m:
      flag = True
      
if flag:
  print(':(')
else:
  print('Yay!')

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a=list[int(input()) for i in range(5)]
b=int(input())
if a[4]-a[0]>b:
  print('Yay!')
else:
  print(':(')

a=[int(input()) for i in range(5)]
b=int(input())
if a[4]-a[0]<=b:
  print('Yay!')
else:
  print(':(')


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
inputstr1 = [input() for inputstr1 in range(6)]

a = int(inputstr1[0])
b = int(inputstr1[1])
c = int(inputstr1[2])
d = int(inputstr1[3])
e = int(inputstr1[4])
k = int(inputstr1[5])

inputmax = max(a, b, c, d, e)
inputmin = min(a, b, c, d, e)


if inputmax - inputmin <= k :
    print("yay!")
else:
    print(":(")

inputstr1 = [input() for inputstr1 in range(6)]

a = int(inputstr1[0])
b = int(inputstr1[1])
c = int(inputstr1[2])
d = int(inputstr1[3])
e = int(inputstr1[4])
k = int(inputstr1[5])

inputmax = max(a, b, c, d, e)
inputmin = min(a, b, c, d, e)


if inputmax - inputmin <= k :
    print("Yay!")
else:
    print(":(")

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
list = [a,b,c,d,e]
flag = 0

for first_num in list:
    for second_num in list:
        if (first_num - second_num) > abs(k):
          flag = 1
 
if flag == 0:
  print('Yay!')  
else:
  print(':(')
   

a = input()
b = input()
c = input()
d = input()
e = input()
k = input()


list = [a,b,c,d,e]
flag = 0


for first_num in list:
    for second_num in list:
        if (int(first_num) - int(second_num)) > abs(int(k)):
          flag = 1

if flag == 0:
  print('Yay!')
else:
  print(':(')


Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):

dishes = [input() for _ in range(5)]

sum_dishes = 0
last_dish = 0
last_tmp = 0
for idx, dish in enumerate(dishes):
    tmp = 10 - int(dish[-1])
    dish = int(dish)
    if tmp == 10:
        sum_dishes += dish
    elif tmp > last_tmp:
        sum_dishes += last_dish + last_tmp
        last_dish = dish
        last_tmp = tmp
        last_idx = idx
    else:
        sum_dishes += dish + tmp

print(sum_dishes + int(dishes[last_idx]))

a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

poles = []
poles.append(a)
poles.append(b)
poles.append(c)
poles.append(d)
poles.append(e)

able_poles = 0
for i in range(4):  
    for j in range(i+1, 5):
        if abs(poles[i]-poles[j]) <= k:
            able_poles += 1
if able_poles == 10:  
    print('Yay!')
else:
    print(':(')


Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
arr=[]
for i in range(5):
    arr.append(int(input()))
k = int(input())

print(arr,k)
i=0
singi=0
if k >= arr[4] - arr[0]:
    print('Yay!')
else:
    print(':(')

arr=[]
for i in range(5):
    arr.append(int(input()))
k = int(input())

i=0
singi=0
if k >= arr[4] - arr[0]:
    print('Yay!')
else:
    print(':(')

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a,b,c,d,e,k = [int,input()] for i range(6)]

print("Yay!" if abs(a-e) <= k else ":(" )

A = map(int,input())

print("Yay!" if A <= A[5] else ":(" )

a,b,c,d,e,k=[int(input()) for i in range(6)]
print("Yay!" if abs(a-e)<=k else ":(")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = int(input())
b = input()
c = input()
d = input()
e = int(input())
k = int(input())
if e - a <= k:
    print("Yey!")
else:
    print(":(")

a = int(input())
b = input()
c = input()
d = input()
e = input()
k = int(input())
if e - a <= k:
    print("Yey!")
else:
    print(":(")

a = int(input())
b = input()
c = input()
d = input()
e = input()
k = input()
if e - a <= k:
    print("Yey!")
else:
    print(":(")

a = int(input())
b = input()
c = input()
d = input()
e = int(input())
k = int(input())
if e - a <= k:
    print("Yay!")
else:
    print(":(")

Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = []
for i in range(5):
    a.append(int(input()))

k = int(input())
if a[5] - a[0] > k:
    print(":(")
else:
    print("Yay!")

a = []
for i in range(5):
    a.append(int(input()))

k = int(input())
if a[4] - a[0] > k:
    print(":(")
else:
    print("Yay!")

Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())

if max((b-a),(c-a),(d-a),(e-a),(c-b),(d-b),(e-b),(d-c),(e-c),(e-d)) < k:
  print(":(")
else:
  print("Yay!")

a,b,c,d,e,k=list(int(input()) for _ in range(6))
if e-a > k:
  print(":(")
else:
  print("Yay!")

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
order = [int(input()) for i in range(5)]
order = list(map(lambda x: -(-x //10), order))
sum_order = sum(order)

diff = (sorted(map(lambda x: (x % 10), order)))
diff = [i for i in diff if i != 0]

print ((sum_order * 10) - 10 + diff[0])

order = [int(input()) for i in range(5)]
diff = (sorted(map(lambda x: (x % 10), order)))
diff = [i for i in diff if i != 0]

sum_order = sum(list(map(lambda x: -(-x //10), order))) * 10

if diff != []:
    sum_order += diff[0]
    
print (sum_order)

anntena = [int(input()) for i in range(5)]
k = int(input())

print(":(") if anntena[4] - anntena[0] > k else print("Yay!")

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a=[int(input()) for i in range(5)]
k=int(input())
for i in range(4):
  for j in range(1,5):
    if abs(a[i]-a[j])>k:
      print(':(')
      exit()
print('Yay')


a=[int(input()) for i in range(5)]
k=int(input())
for i in range(n-4):
  for j in range(1,n):
    if abs(a[i]-a[j])>k:
      print(':(')
      exit()
print('Yay')

a=[int(input()) for i in range(5)]
k=int(input())
for i in range(n-1):
  for j in range(1,n):
    if abs(a[i]-a[j])>k:
      print(':(')
      exit()
print('Yay')

a=[int(input()) for i in range(5)]
k=int(input())
for i in range(4):
  for j in range(1,5):
    if abs(a[i]-a[j])>k:
      print(':(')
      exit()
print('Yay!')


Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a=[int(input())for _ in[0]*6];print((~-a[0]//min(a[1:]))+5)

a,*b=eval('int(input()),'*6);print(~-a//min(b)+5)

a=[int(input())for i in[0]*6];import math;print(math.ceil(a[0]/min(a[1:])))

a,*_,e,k=eval('int(input()),'*6);print(':('*(e-a>k)|'Yay!')

a=[int(input())for i in[0]*6];import math;print(math.ceil(a[0]/min(a[1:]))+4)

a,k=[int(input())for i in[0]*5],int(input());print(':('if a[4]-a[0]>k else'Yay!')

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = [int(input()) for _ in range(5)]
k = int(input())
print(a)
if a[-1] - a[0] <= k:
    print('Yay!')
else:
    print(':(')

a = [int(input()) for _ in range(5)]
k = int(input())
if (a[-1] - a[0]) <= k:
    print('Yay!')
else:
    print(':(')

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = [int(input())for in range(6)]
if a[4] - a[0] > a[5]:
    print(":(")
else:
    print("Yay!")

a = [int(input())for i in range(6)]
if a[4] - a[0] > a[5]:
    print(":(")
else:
    print("Yay!")

Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
`a=[0]*5
for i in range(5):
    a[i]=int(input().strip())
k=int(input().strip())
d=max(a)-min(a)
if d<=k:
    print("Yay!")
else:
    print(":(")

a=[0]*5
for i in range(5):
    a[i]=int(input().strip())
k=int(input().strip())
d=max(a)-min(a)
if d<=k:
    print("Yay!")
else:
    print(":(")

Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

list = [a, b, c, d, e]

can = False
for i in range(len(list)):
  for j in range(len(list)):
    if i == j:
      continue
    if abs(list[i] - list[j]) > k:
      break
      
if can:
  print("Yay!")
else:
  print(":(")


a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

if e - a <=k:
  print("Yay!")
else:
  print(":(")

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
import numpy as np
N = input()
a = []
for i in range(N):
    a.append(input())
dero=np.zeros((25,2))
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]

import numpy as np
N = input()
a = []
for i in range(N):
    a.append(input())
dero=np.zeros((25,2))
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]
frag=0
for i in range(25):
  if dero[i][0]>dero[i][1]:
    frag=1
    print(dero[i][0])
if frag==0:
  print(":(")

import numpy as np

unchi=input()
dero=np.zeros((25,2))
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=unchi[j]-unchi[i]
    dero[i*5+j][1]=unchi[5]
frag=0
for i in range(25):
  if dero[i][0]>dero[i][1]:
    frag=1
    print(dero[i][0])
if frag==0:
  print(":(")

import numpy as np
main():
  n=6
  a=[int(input()) for i in range(n)]
  dero=np.zeros((25,2))
  for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]
  frag=0
  for i in range(25):
  if dero[i][0]>dero[i][1]:
    frag=1
  if frag==0:
    print("Yay!")
  else:
    print(":(")

n=6
a=[int(input()) for i in range(n)]
dero=np.zeros((25,2))
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]
frag=0
for i in range(25):
  if dero[i][0]>dero[i][1]:
    frag=1
if frag==0:
  print("Yay!")
else:
    print(":(")

import numpy as np
a=list(input())
dero=np.zeros((25,2))
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]
frag=0
for i in range(25):
  if dero[i][0]>dero[i][1]:
    frag=1
if frag==0:
  print("Yay!")
else:
    print(":(")

import numpy as np
n=6
a=[int(input()) for i in range(n)]
dero=np.zeros((25,2))
for i in range(5):
  for j in range (5):
    dero[i*5+j][0]=a[j]-a[i]
    dero[i*5+j][1]=a[5]
frag=0
for i in range(25):
  if dero[i][0]>dero[i][1]:
    frag=1
if frag==0:
  print("Yay!")
else:
    print(":(")

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
B = [int(input()) for _ in range(5)]
A = [10-int(str(B[i])[-1]) for i in range(5) if str(B[i])[-1] != "0"]
if len(A) != 0:
	A.remove(max(A))
print(sum(B)+sum(A))

B = [int(input()) for _ in range(5)]
A = [10-int(str(B[i])[-1]) for i in range(5) if str(B[i])[-1] != "0"]
A.remove(max(A))
print(sum(B)+sum(A))

a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
D = "Yay!"
antena = [a,b,c,d,e]
for st in range(5):
  for end in  range(st+1,5):
    if abs(antena[st] - antena[end]) > k:
      D = ":("
print(D)
  

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):


for i in range(6):
    a[i] = int(input())

out_flag = False
    
for i in range(4):
    if a[i+1]-a[i] > a[5]:
        out_flag = True

if out_flag:    
    print(':(')
else:
    print('Yay!')




a = []

for i in range(6):
    a.append(int(input()))

if a[4] -a[0] <= a[5]:
    print('Yay!')
else:
    print(':(')



Verdicts: Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
foods = [int(input()) for i in range(5)]
time = 0
rest = list(map(lambda x: x % 10, foods))
for i in range(5):
    if rest[i] == 0:
        time += foods[i]
    else:
        time += foods[i] - rest[i] + 10

if not any(rest):
   print(time)
else:
    print(time - 10 + min([i for i in rest if i != 0]))

import heapq

X, Y, Z, K = map(int, input().split())
A = sorted([int(i) for i in input().split()], reverse=True)
B = sorted([int(i) for i in input().split()], reverse=True)
C = sorted([int(i) for i in input().split()], reverse=True)

heap = []
heapq.heappush(heap, (-(A[0] + B[0] + C[0]), 0, 0, 0))
added = set([(0, 0, 0)])
for _ in range(K):
    p, i, j, k = heapq.heappop(heap)
    if (i + 1, j, k) not in added and i + 1 < X:
        heapq.heappush(heap, (-(A[i + 1] + B[j] + C[k]), i + 1, j, k))
        added.add((i + 1, j, k))
    if (i, j + 1, k) not in added and j + 1 < Y:
        heapq.heappush(heap, (-(A[i] + B[j + 1] + C[k]), i, j + 1, k))
        added.add((i, j + 1, k))
    if (i, j, k + 1) not in added and k + 1 < Z:
        heapq.heappush(heap, (-(A[i] + B[j] + C[k + 1]), i, j, k + 1))
        added.add((i, j, k + 1))
    print(-p)

atn = [int(input()) for i in range(5)]
k = int(input())
b = 1
for i in range(4):
    for j in range(4 - i):
        if abs(atn[i] - atn[i + j + 1]) > k:
            b = 0

if b:
    print('Yay!')
else:
    print(':(')

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
import sys
array = [0,0,0,0,0,0]
for I in range(len(array)):
    array[I] = int(input())
    if not ( 0 <= array[I] <= 123 ):
        sys.exit()
print('Yey!') if (array[4] - array[0]) <= array[-1] else print(':(')

import sys
array = [0,0,0,0,0,0]
for I in range(len(array)):
    array[I] = int(input())
    if not ( 0 <= array[I] <= 123 ):
        sys.exit()
print('Yay!') if (array[4] - array[0]) <= array[-1] else print(':(')

Verdicts: Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
data_ls = []
for i in range(5):
  data_ls.append(int(input()))
k = int(input())
sort(data_ls)
if data_ls[-1] - data_ls[0] > k:
  print("Yay!")
else:
  print(":(")

data_ls = []
for i in range(5):
  data_ls.append(int(input()))
k = int(input())
data_ls = sorted(data_ls)
if data_ls[-1] - data_ls[0] > k:
  print("Yay!")
else:
  print(":(")

data_ls = []
for i in range(5):
  data_ls.append(int(input()))
k = int(input())
data_ls.sort()
if data_ls[-1] - data_ls[0] > k:
  print(":(")
else:
  print("Yay!")

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
# coding: utf-8
# Your code here!
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
if a-b>k and a-c>k and a-d>k and a-e>k and b-c>k and b-d>k and b-e>k and c-d>k and c-e>k and d-e>k:
    print("Yay!")
else:
    print(":(")

# coding: utf-8
# Your code here!
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
if abs(a-b)>k and abs(a-c)>k and abs(a-d)>k and abs(a-e)>k and abs(b-c)>k and abs(b-d)>k and abs(b-e)>k and abs(c-d)>k and abs(c-e)>k and abs(d-e)>k:
    print("Yay!")
else:
    print(":(")

# coding: utf-8
# Your code here!
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
if e-a<=k
    print("Yay!")
else:
    print(":(")

# coding: utf-8
a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())

if e-a>k:
    print(":(")
else:
    print("Yay!")




Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: In AtCoder city, there are five antennas standing in a straight line. They are called Antenna A, B, C, D and E from west to east, and their coordinates are a, b, c, d and e, respectively.   Two antennas can communicate directly if the distance between them is k or less, and they cannot if the distance is greater than k.   Determine if there exists a pair of antennas that cannot communicate **directly**.   Here, assume that the distance between two antennas at coordinates p and q (p < q) is q - p.

Submission attempts (in order):
import sys

antennas = [int(input()) for _ in range(5)]
k = int(input())

for p in range(5):
  for q in range(p+1,5):
    if antennas[q] - antennas[p] > k:
      print ':('
      sys.exit()

print 'Yay!'
      
    

import sys
 
antennas = [int(input()) for _ in range(5)]
k = int(input())
 
for p in range(5):
  for q in range(p+1,5):
    if antennas[q] - antennas[p] > k:
      print ':('
      sys.exit()

print 'Yay!'

import sys
 
antennas = [int(input()) for _ in range(5)]
k = int(input())
 
for p in range(5):
  for q in range(p+1,5):
    if antennas[q] - antennas[p] > k:
      print (':(')
      sys.exit()

print ('Yay!')

Verdicts: Runtime Error

Runtime Error

Accepted