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):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())

k = int(input())

diff = 0

ant_list = []

ant_list.append(a)
ant_list.append(b)
ant_list.append(c)
ant_list.append(d)
ant_list.append(e)

judge = True

for i in range(len(ant_list) - 1):

    for j in range(5-i):
        diff  = ant_list[4-j] - ant_list[i]
        print(diff)
        if diff > k:
            judge = False
            break
    else:
        continue

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

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

k = int(input())

diff = 0

ant_list = []

ant_list.append(a)
ant_list.append(b)
ant_list.append(c)
ant_list.append(d)
ant_list.append(e)

judge = True

for i in range(len(ant_list) - 1):

    for j in range(5-i):
        diff  = ant_list[4-j] - ant_list[i]

        if diff > k:
            judge = False
            break
    else:
        continue

if judge:
    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 = map(int,open(0).read().split())
if max(e-a) <= k:
    print("Yay!")
else:
    print(":(")

a,b,c,d,e,k = map(int,open(0).read().split())
if max(b-a,c-b,d-c,e-d) <= k:
    print(":(")
else:
    print("Yay!")


a,b,c,d,e,k = map(int,open(0).read().split())
if e-a <= k:
    print("Yay!")
else:
    print(":(")


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 sys
import itertools

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

a = list(map(int,(input().split())))
b = list(map(int,(input().split())))
c = list(map(int,(input().split())))

a.sort(reverse=True)
b.sort(reverse=True)
c.sort(reverse=True)

comb_a = [a[0]]
comb_b = [b[0]]
comb_c = [c[0]]
next = []
sum = []

comb = list(itertools.product(comb_a,comb_b,comb_c))
num_comb = len(comb)

#while num_comb < k*2 and num_comb < 3000:
while num_comb < 3000:


    next = []
    for i in a,b,c:
        if len(i) >= 2:
            next.append(i[0] - i[1])
        if len(i) == 1:
            next.append(10000000001)
    if min(next) != 10000000001:
        if len(a) >= 2 and min(next) == a[0] - a[1]:
            comb_a.append(a[1])
            a.pop(0)
        elif len(b) >= 2 and min(next) == b[0] - b[1]:
            comb_b.append(b[1])
            b.pop(0)
        elif len(c) >= 2 and min(next) == c[0] - c[1]:
            comb_c.append(c[1])
            c.pop(0)
    else:
        break
    comb = list(itertools.product(comb_a,comb_b,comb_c))
    num_comb = len(comb)
    
for i in comb:
    sum.append(i[0]+i[1]+i[2])
sum.sort(reverse=True)
for i in range(k):
    print(sum[i])


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

result = 0
if e - a <= k:
    print('Yay!')
elif e - a > k:
    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())

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

last = 10
time = 0

for item in array:
	r = item%10
	if r != 0:
		time += (int(item/10)+1)*10
		last = min(last, r)
	else:
		time += item

print(time-10+last)

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

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

k = int(input())

first = ant[0]
for i in reversed(range(1, 5)):
	if ant[i] -  first > k:
		print (":(")
		quit()

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):
A = [0]*5
for i in range(5):
    A[i] = int(input())
k = int(input())
flag = 0
for j in range(4):
    for k in range(4-j):
        if abs(A[j]-A[3-k]) > k:
            flag = 1
            break

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

A = [0]*5
for i in range(5):
    A[i] = int(input())
k = int(input())
flag = 0
for j in range(4):
    for k in range(4-j):

        if abs(A[j]-A[3-k]) > k:

            print(":(")
            flag = 1
            break

if flag==0:
    print("Yay!")

A = [0]*5
for i in range(5):
    A[i] = int(input())
k = int(input())
if A[4]-A[0]>k:
    print(":(")
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,b,c,d,e,k = map(int, [input() for i in range(6)])
if (e - a) < k:
  print('Yay1')
else:
  print(':(')

a,b,c,d,e,k = map(int, [input() for i in range(6)])
if (e - a) <= k:
  print('Yay1')
else:
  print(':(')

l =[]
for i in range(6):
  a =int(input())
  l.append(a)
if l[-2] - l[0] > l[-1]:
  print(':(')
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, b, c, d, e = int(input()), int(input()), int(input()), int(input()), int(input())
if abs(e-a) > int(input()):
  print("Yay!")
else:
  print(":(")

a, b, c, d, e = int(input()), int(input()), int(input()), int(input()), int(input())
if abs(e-a) <= int(input()):
  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 e-a>k:
  print(':(')
else:
  print('Yey!')

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

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):
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()))

d = [e1+e2 for e1 in a for e2 in b]
d.sort(reverse=True)
d = d[:k]

e = [e1+e2 for e1 in d for e2 in c]
e.sort(reverse=True)

for i in range(k):
  print(e[i])

a = []
for i in range(5):
  a.append(int(input()))
k = int(input())
if a[4]-a[0]<=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):
s = [input() for i in range(6)]
if s[4]-s[0]>s[5]:
  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(":(")
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 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(':(')


        

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):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
if e-d > k or e-c > k or e-b > k or e-a > a or d-c > k or d-b > k or d-a > k or c-b > k or c-a > k or b-a > 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: 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=input()
b=input()
c=input()
d=input()
e=input()
k=input()
f=min(a,b,c,d,e)
g=max(a,b,c,d,e)
h=g-f
if h <= k:
  print('Yay')
else:
  print(':(')

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
f=min(a,b,c,d,e)
g=max(a,b,c,d,e)
h=g-f
if h <= k:
  print('Yay')
else:
  print(':(')

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


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())

def diff(x, y, z = k):
  if abs(x - y) > z:
    return 1
  else:
    return 0
  
num = 0

num += diff(a, e)
num += diff(a, d)
num += diff(a, c)
num += diff(a, b) 
num += diff(b, e)
num += diff(b, d)
num += diff(b, c)
num += diff(c, e)
num += diff(c, d)
num += diff(d, e)

if num > 0:
  print("Yay!")
else:
  print(":(")

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


k = int(input())

def diff(x, y, z = k):
  if abs(x - y) > z:
    return 1
  else:
    return 0
  
num = 0

num += diff(a, e)
num += diff(a, d)
num += diff(a, c)
num += diff(a, b) 
num += diff(b, e)
num += diff(b, d)
num += diff(b, c)
num += diff(c, e)
num += diff(c, d)
num += diff(d, e)

if num == 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 = int(input())
B = int(input())
C = int(input())
D = int(input())
E = int(input())

times = [A, B, C, D, E]

def calRest(times):
	rest = 10
	for time in times:
		if time % 10 == 0:
			continue
		elif time % 10 < rest:
			rest = time % 10
	return 10 - rest

sumTime = sum([10 * (int((time-1)/10)+1) for time in times])
rest = calRest(times)
neatTime = sumTime - rest
print(neatTime)

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

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())

difs = [b-a, c-b, d-c, e-d]
Mdif = Max(difs)
if Mdif <= k:
  print("Yay!")
else:
  print(":(")

[a, b, c, d, e] = [int(input()) for i in range(5)]
k = int(input())

difs = [b-a, c-b, d-c, e-d]
Mdif = Max(difs)
if Mdif <= 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(":(")

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):
r=[]
for _ in range(5):
  r.append(int(input()))

k=int(input())

i=0
while i<4:
  j=i+1
  while j<5:
    if abs(r[i]-r[j])>k:
      print("Yay!")
      exit()
    
    j+=1
  i+=1
  
print(":(")

r=[]
for _ in range(5):
  r.append(int(input()))

k=int(input())

i=0
while i<4:
  j=i+1
  while j<5:
    if abs(r[i]-r[j])>k:
      print(":(")
      exit()
    
    j+=1
  i+=1
  
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):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
if abs(a-b) > k or abs(a-c) > k or abs(a-d) > k or abs(a-e) > k or abs(b-c) > k or abs(b-d) > k or abs(b-e) > k or abs(c-d) > k or abs(c-e) > k orabs(d-e) > k :
  print(':(')
else:
  print('Yay!')

a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
if abs(a-b) > k or abs(a-c) > k or abs(a-d) > k or abs(a-e) > k or abs(b-c) > k or abs(b-d) > k or abs(b-e) > k or abs(c-d) > k or abs(c-e) > k or abs(d-e) > 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):
list = []
list.append(input())
list.append(input())
list.append(input())
list.append(input())
list.append(input())

k = input()

ju = "Yay!"

for i in range(5):
    for j in range(5):
        if i == j:
            pass
        else:
            dis = abs(int(list[i]) - int(list[j]))

            if dis <= int(k):
                ju = ":("

print(ju)


list = []
list.append(input())
list.append(input())
list.append(input())
list.append(input())
list.append(input())

k = input()

ju = "Yay!"

for i in range(5):
    for j in range(5):
        if i == j:
            pass
        else:
            dis = int(list[i]) - int(list[j])

            if dis <= int(k):
                ju =":("

print(ju)

list = []
list.append(input())
list.append(input())
list.append(input())
list.append(input())
list.append(input())

k = input()

ju = "Yay!"

for i in range(5):
    for j in range(5):
        if i == j:
            pass
        else:
            dis = abs(int(list[i]) - int(list[j]))
            print(dis)
            if dis > int(k):
                ju = ":("

print(ju)

list = []
list.append(input())
list.append(input())
list.append(input())
list.append(input())
list.append(input())

k = input()

ju = "Yay!"

for i in range(5):
    for j in range(5):
        if i == j:
            pass
        else:
            dis = abs(int(list[i]) - int(list[j]))
            if dis > int(k):
                ju = ":("

print(ju)


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):
a,b=5,10
for i in range(5):
    i=int(input())
    a+=(i-1)//10
    if 0<i%10<b:
        b=i%10
print(a*10-(10-b))


a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
lis=[abs(a-b),abs(a-c),abs(a-d),abs(a-e),abs(b-c),abs(b-d),abs(b-e),abs(c-d),abs(c-e),abs(d-e)]
lis2=sorted(lis)
print(lis2)
if lis2[-1]<=k:
    print("Yay!")
else:
    print(":(")

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
lis=[abs(a-b),abs(a-c),abs(a-d),abs(a-e),abs(b-c),abs(b-d),abs(b-e),abs(c-d),abs(c-e),abs(d-e)]
lis2=sorted(lis)
print(lis2)
if lis2[-1]<k:
    print("Yay!")
else:
    print(":(")

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
lis=[abs(a-b),abs(a-c),abs(a-d),abs(a-e),abs(b-c),abs(b-d),abs(b-e),abs(c-d),abs(c-e),abs(d-e)]
lis2=sorted(lis)
if lis2[-1]<=k:
    print("Yay!")
else:
    print(":(")

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):
import math

A = []
N = int(input())
for i in range(5):
    a = int(input())
    A.append(a)
min_t = min(A)
"""
if N % min_t == 0:
    a = N // min_t
else:
    a = N // min_t + 1
"""
a = math.ceil(N / min_t)
print(a + 5)


A = []
for i in range(6):
    A.append(int(input()))
if A[4]-A[0] <= A[5]:
    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):
n = input().rsplit()
points = [int(i) for i in n]
dist = points[-2] - points[0]
if dist > points[-1]:
    print(':(')
else:
    print('Yay!')

n = input().rsplit()
points = [int(i) for i in n]
distances = []
for i in range(len(points)-2):
   dist = points[-2] - points[i]
   distances.append(dist)

if max(distances) > points[-1]:
    print(':(')
else:
    print('Yay!')

x = []
for i in input().split():
    x.append(int(i))

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

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

a, b, c, d, e, k = [int(i) for i in input().split()]
if e-a > k:
    print(':(')
else:
    print('Yay')

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

Verdicts: Runtime Error

Runtime Error

Runtime Error

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):
x,y=[],[]
t=10
for i in range(5):
    x.append(int(input()))
    y.append(x[i]%10)
    if 0<y[i]<t:
        t=y[i]
    if x[i]%10!=0:
        x[i]=((x[i]//10)+1)*10
    y[i]=x[i]
print(sum(y)+t-10)

x=[]
for i in range(5):
    x.append(int(input()))
k=int(input())
ans="Yay!"
for j in range(5):
    for s in range(1,5):
        if j>=s:
            break
        if x[s]-x[j]>k:
            ans=":("
print(ans)

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):
#!/usr/bin/env python
a = input()
b = input()
c = input()
d = input()
e = input()
k = input()

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

#!/usr/bin/env python
a = input()
b = input()
c = input()
d = input()
e = input()
k = input()

if int(e) - int(a) > int(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):
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))


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

k = int(input())
if antennas[4] - antennas[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):
for i in range(5):
    I=list(int(input()))
k=int(input())
if max(I)-min(I)<=k:
    print("Yes")
else:
    print("No")


for i in range(5):
    I=list(map(int,input()))
k=int(input())
if I[4]-I[0]<=k:
    print("Yay!")
else:
    print(":(")


or i in range(5):
    I=list(map(int,input().split()))
k=int(input())
if max(I)-min(I)<=k:
    print("Yay!")
else:
    print(":(")


I=[]
for i in range(5):
    I.append(int(input()))
k=int(input())
if I[4]-I[0]<=k:
    print("Yay!")
else:
    print(":(")

    

Verdicts: 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):
a,b,c,d,e,k= map(int,input().split())
if e-a>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(':(')
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()) for _ in range(5)]
print("Yay!" if (A[-1]-A[0])>int(input()) else ":(")

A=[int(input()) for _ in range(5)]
print("Yay!" if (A[-1]-A[0])<=int(input()) 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):
t = "Yay!"
f = ":("

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

if max(antennas) <= k:
  print(t)
else:
  flag = True
  for i in antennas:
    for j in antennas:
      if abs(i-j) >= k:
        flag = False
  if flag: print(t)
  else: print(f)
    

import math
dishes = [int(input()) for _ in range(5)]
lead_times = [int(math.ceil(t/10))*10 - t for t in dishes]
max_idx = lead_times.index(max(lead_times))
result = 0
for i in range(5):
  result += dishes[i]
  if i != max_idx:
    result += lead_times[i]
print(result)

t = "Yay!"
f = ":("

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

if max(antennas) <= k:
    print(t)
else:
    flag = True
    for i in antennas:
        for j in antennas:
            if abs(i - j) >= k:
                flag = False
    if flag:
        print(t)
    else:
        print(f)

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 sys
a=list(map(int,open(0).read().split()))
for i in range(5):
  for j in range(5):
    if i==j:
      continue
    elif abs(a[i]-a[j])>a[5]:
      print(':(')
      sys.exit()
else:
  print('Yey!')

import sys
a=list(map(int,open(0).read().split()))
for i in range(5):
  for j in range(5):
    if i==j:
      continue
    elif abs(a[i]-a[j])>a[5]:
      print(':(')
      sys.exit()
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):
a = map(int, input())
b = map(int, input())
c = map(int, input())
d = map(int, input())
e = map(int, input())
k = map(int, input())
if e - a =< k:
  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: 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())
ls=[a,b,c,d,e]
for i in range(len(ls)):
    for j in range(len(ls)-i):
        if ls[i] - ls[j] >= k:
            print(':(')
            break
        else:
            continue
    break
else:
    print('Yay!')

a=int(input())
b=int(input())
c=int(input())
d=int(input())
e=int(input())
k=int(input())
ls=[a,b,c,d,e]
for i in range(len(ls)):
    for j in range(len(ls)-i):
        if ls[i] - ls[j] > k:
            print(':(')
            break
    else:
        continue
    break
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):
a, _,e,k=map(int,open(0).read().split())
print(e-a<=k ‘Yay!’or ‘:(‘)

a,*_,e,k=map(int,open(0))
print('Y:a(y !'[e-a>k::2])

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):
l=[int(input()) for i in range(5)]
flag=False
k=int(input())
for i in range(len(l)):
    for j in range(i+1,len(l)):
        if(l[j]-l[i]<=k):
            flag=True
            break
    if(flag):
        break
if(flag):
    print(":(")
else:
    print('Yay!')

l=[int(input()) for i in range(5)]
flag=False
k=int(input())
for i in range(len(l)):
    for j in range(i+1,len(l)):
        if(l[j]-l[i]<=k):
            flag=True
        else:
            flag=False
            break
    if(not flag):
        break
if(not flag):
    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):
a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())

l = []
l.append(a)
l.append(b)
l.append(c)
l.append(d)
l.append(e)
ans = 0
for i in range(5):
    for j in range(i+1,5):
        if l[j] - l[i] > k :
            ans += 1

if ans > 0 :
    print("Yay!")
else :
    print(":(")


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

l = []
l.append(a)
l.append(b)
l.append(c)
l.append(d)
l.append(e)
ans = 0
for i in range(5):
    for j in range(i+1,5):
        if l[j] - l[i] > k :
            ans += 1

if ans = 0 :
    print("Yay!")
else :
    print(":(")


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

l = []
l.append(a)
l.append(b)
l.append(c)
l.append(d)
l.append(e)
ans = 0
for i in range(5):
    for j in range(i+1,5):
        if l[j] - l[i] > k :
            ans += 1

if ans == 0 :
    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):
x = list(map(int, input().split()))
if x[4] - x[0] < x[-1]:
    print("Yay!")
else:
    print(":(")

x = list(map(int, input()))
if x[4] - x[0] < x[-1]:
    print("Yay!")
else:
    print(":(")

x = [int(input()) for i in range(6)]
if x[4] - x[0] <= x[-1]: print("Yay!")
else: print(":(")

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 =input()
b =input()
c =input()
d =input()
e =input()
k =input()

if b-a and c-b and d-c and e-d <= k:
   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(':(')
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

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(""))
M=max(a,b,c,d,e)
m=min(a,b,c,d,e)
sa=M-m
if sa>=k:
    print('Yay!')
else:
    print(':(')

a=int(input(""))
b=int(input(""))
c=int(input(""))
d=int(input(""))
e=int(input(""))
k=int(input(""))
M=max(a,b,c,d,e)
m=min(a,b,c,d,e)
sa=M-m
if sa<=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):
l = []
flag = 0
for i in range(6):
	l.append(int(input()))
print(l)

for i in range(4):
	for j in range(i+1,5):
		if not abs(l[i] - l[j]) < l[5]:
			flag = 1
			break

if not flag == 1:
	print("Yay!")
else:
	print(":(")

l = []
for i in range(6):
	l.append(int(input()))

if abs(l[0] - l[4]) <= l[5]:
	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):
for i in range(6):
  A[i]=int(input())
  
isOK=True
for i in range(5):
  for j in range(5):
    if(abs(A[i]-A[j]) > A[6]):
      isOK=False
      
if(isOK):
  print("Yay!")
else:
  print(":(")

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

isOK=True

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


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

isOK=True

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

A=[0]*6
for i in range(6):
  A[i]=int(input())
  
isOK=True
for i in range(5):
  for j in range(i,5):
    if(abs(A[i]-A[j]) > A[5]):
      isOK=False
      
if(isOK):
  print("Yay!")
else:
  print(":(")


Verdicts: Runtime Error

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 = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
dis=list[a,b,c,d,e,k]

if max(dis)-min(dis)>=K:
  print(":(")
else("Yay!") 

a = int(input())
b = int(input())
c = int(input())
d = int(input())
e = int(input())
k = int(input())
dis =[]
dis.append(a)
dis.append(b)
dis.append(c)
dis.append(d)
dis.append(e)

if max(dis)-min(dis)>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):
anntena = []
for i in range(5):
  anntena.append(int(input()))
k = int(input())

if (anntena[-1] - anntena[0]) <= k:
  print('Yey!')
else:
  print(':(')


anntena = []
for i in range(5):
    anntena.append(int(input())
k = int(input())
                 
if anntena[4] - anntena[0] <= k:
    print('Yey!')
else:
    print(':(')


anntena = []
for i in range(5):
  anntena.append(int(input())
k = int(input())
                 
if anntena[4] - anntena[0] <= k:
  print('Yey!')
else:
  print(':(')


anntena = []
for i in range(5):
	anntena.append(int(input())
k = int(input())
                 
if anntena[4] - anntena[0] <= k:
	print('Yey!')
else:
    print(':(')

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

if (anntena[-1] - anntena[0]) <= k:
  print('Yay!')
else:
  print(':(')


Verdicts: Wrong Answer

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):
a, b, c, d, e = [int(input) for i in range(5)]
k = int(input())
if e-a > k*4:
  print(":(")
elif e-b > k*3 or d-a > k*3:
  print(":(")
elif e-c > k*2 or d-b > k*2 or c-a > k*2:
  print(":(")
elif e-d > k or d-c > k or c-b > k or b-a > k:
  print(":(")
else:
  print("Yay!")

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

Verdicts: Runtime Error

Accepted