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()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
        if b[i] == 10:
        	c.append(int(a[i]))
        if b[i] != 10:
        	c.append(int(a[i] +10 -b[i]))
    d = sum(c)
    mini = min(b)
    ans = d - 10 + mini
print(ans)
    
        
          
      
      



a = []
for i in range(5):
    a.append(int(input()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
        if b[i] == 10:
                c.append(int(a[i]))
        if b[i] != 10:
                c.append(int(a[i]) +10 -int(b[i]))
    d = sum(c)
    mini = min(b)
    ans = d - 10 + mini
print(ans)
    

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



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

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


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



a = []
for i in range(5):
    a.append(int(input()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
    	c.append(int(a[i]) +10 -int(b[i]))
    d = sum(c)
    mini = min(b)
    ans = d - 10 + mini
print(ans)
    

a = []
for i in range(5):
    a.append(int(input()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
        if b[i] == 10:
                c.append(int(a[i]))
        if b[i] != 10:
                c.append(int(a[i] +10 -b[i]))
        d = sum(c)
        mini = min(b)
        ans = d - 10 + mini
print(ans)

N = int(input())
cyapa = []
for i in range (1,6):
    cyapa.append(int(input()))
kasu = min(cyapa)
if kasu >= N:
    ans = 5
else:
    ans = 5 + (N-1)//kasu
print(ans)

a = []
for _ in range(5):
  a.append(int(input()))
b =[]
c = []
for i in range(5):
  b[i] = a[i]
for i in range(5):
  while b[i] > 10:
  	b[i] = b[i] - 10
  if min(b[i]) == 10:
  	print(sum(a))
  else:
  	for i in range(5):
    	if b[i] == 10:
          c[i] = a[i]
        if b[i] != 10:
          c[i] = a[i] +10 -b[i]
        d = sum(c)
        mini = min(b)
        ans = d - 10 + mini
        print(ans)
    

a = []
for _ in range(5):
  a.append(int(input()))
b =[]
c = []
for i in range(5):
  b[i] = a[i]
for i in range(5):
  while b[i] > 10:
  	b[i] = b[i] - 10
  if min(b[i]) == 10:
    return sum(a)
  else:
    for i in range(5):
    	if b[i] == 10:
          c[i] = a[i]
        else:
          c[i] = a[i] +10 -b[i]
        d = sum(c)
        mini = min(b)
        ans = d - 10 + mini
        return ans
    

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


a = []
for i in range(5):
    a.append(int(input()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
    	c.append(int(a[i] +10 -b[i]))
    d = sum(c)
    mini = min(b)
    ans = d - 10 + mini
print(ans)
    

a = []
for i in range(5):
    a.append(int(input()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
        if b[i] == 10:
                c.append(int(a[i]))
        if b[i] != 10:
                c.append(int(a[i] +10 -b[i]))
        d = sum(c)
        mini = min(b)
        ans = d - 10 + mini
    print(ans)
    
        

a = []
for i in range(5):
    a.append(int(input()))
b =[]
c = []
for i in range(5):
    b.append(int(a[i]))
for i in range(5):
    while b[i] > 10:
        b[i] = b[i] - 10
if min(b) == 10:
    ans = sum(a)
else:
    for i in range(5):
        if b[i] == 10:
                c.append(int(a[i]))
        if b[i] != 10:
                c.append(int(a[i] +10 -b[i]))
        d = sum(c)
        mini = min(b)
        ans = d - 10 + mini
    print(ans)

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



Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted