Problem:


Score : 300 points

Problem Statement

Find the price of a product before tax such that, when the consumption tax rate is 8 percent and 10 percent, the amount of consumption tax levied on it is A yen and B yen, respectively. (Yen is the currency of Japan.)

Here, the price before tax must be a positive integer, and the amount of consumption tax is rounded down to the nearest integer.

If multiple prices satisfy the condition, print the lowest such price; if no price satisfies the condition, print -1.

Constraints

1 \leq A \leq B \leq 100

A and B are integers.

Input

Input is given from Standard Input in the following format:

A B

Output

If there is a price that satisfies the condition, print an integer representing the lowest such price; otherwise, print -1.

Sample Input 1

2 2

Sample Output 1

25

If the price of a product before tax is 25 yen, the amount of consumption tax levied on it is:

When the consumption tax rate is 8 percent: \lfloor 25 \times 0.08 \rfloor = \lfloor 2 \rfloor = 2 yen.

When the consumption tax rate is 10 percent: \lfloor 25 \times 0.1 \rfloor = \lfloor 2.5 \rfloor = 2 yen.

Thus, the price of 25 yen satisfies the condition. There are other possible prices, such as 26 yen, but print the minimum such price, 25.

Sample Input 2

8 10

Sample Output 2

100

If the price of a product before tax is 100 yen, the amount of consumption tax levied on it is:

When the consumption tax rate is 8 percent: \lfloor 100 \times 0.08 \rfloor = 8 yen.

When the consumption tax rate is 10 percent: \lfloor 100 \times 0.1 \rfloor = 10 yen.

Sample Input 3

19 99

Sample Output 3

-1

There is no price before tax satisfying this condition, so print -1.



Sample input:
2 2


Sample output:
25

Submission status: Wrong Answer

Solution code:
a=input()
(n,m)=a.split(" ")
n=int(n)
m=int(m)
k=n/0.08
j=m/0.1
if n==m:
 if k==j*1/0.8:
    print(int(k))
 else:
    print("-1")
else:
 if k==j:
     print(int(k))
 else:
     print("-1")

Submission status: Wrong Answer

Solution code:
a=input()
(n,m)=a.split(" ")
n=int(n)
m=int(m)
k=n/0.08
j=m/0.1
if n==m:
 if k==j*1/0.8:
    print(int(j*1/0.8))
 else:
    print("-1")
else:
 if k==j:
     print(k)
 else:
     print("-1")

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
def c(x,r):
    return int(-(-x//r))
a1,a2 = c(a,.08), c(a+1,.08)
b1,b2 = c(b,.1), c(b+1,.1)
if a1 > b2 or b1 > a2:
    print(-1)
else:
    print(max(a1,b1))

Submission status: Wrong Answer

Solution code:
a,b = map(float,input().split())

max8 = (a+1) * (1/0.08)
min8 = a * (1/0.08)
max10 = (b+1) * (1/0.1)
min10 = b * (1/0.1)
hachi = [i for i in range(int(min8),int(max8))]
jyuu = [i for i in range(int(min10),int(max10))]
temp = set(hachi)&set(jyuu)
if a > b:
    print('-1')
else:
    if len(temp) >0:
        num = min(temp)
        for i in range(len(temp)):
            if int((num+i)*0.08) == a and int((num+i)*0.1) == b:
                print(num+i)
                break
            num += 1
    else:
        print('-1')

Submission status: Wrong Answer

Solution code:
a,b = map(float,input().split())

max8 = (a+1) * (1/0.08)
min8 = a * (1/0.08)
max10 = (b+1) * (1/0.1)
min10 = b * (1/0.1)
hachi = [i for i in range(int(min8),int(max8))]
jyuu = [i for i in range(int(min10),int(max10))]
temp = list(set(hachi)&set(jyuu))
if a > b:
    print('-1')
else:
    if len(temp) >0:
        for i in range(len(temp)):
            if int(temp[i]*0.08) == a and int(temp[i]*0.1) == b:
                print(temp[i])
                break
    else:
        print('-1')

Submission status: Wrong Answer

Solution code:
a,b = map(float,input().split())

max8 = (a+1) * (1/0.08)
min8 = a * (1/0.08)
max10 = (b+1) * (1/0.1)
min10 = b * (1/0.1)
hachi = [i for i in range(int(min8),int(max8))]
jyuu = [i for i in range(int(min10),int(max10))]
temp = set(hachi)&set(jyuu)
if a > b:
    print('-1')
else:
    if len(temp) >0:
        print(min(temp))
    else:
        print('-1')

Submission status: Wrong Answer

Solution code:
a,b = map(float,input().split())

max8 = (a+1) * (1/0.08)
min8 = a * (1/0.08)
max10 = (b+1) * (1/0.1)
min10 = b * (1/0.1)
hachi = [int(min8),int(min8)+1]
jyuu = [i for i in range(int(min10),int(max10))]
if a > b:
    print('-1')
else:
    if hachi[0] in jyuu:
        print(hachi[0])
    elif hachi[1] in jyuu:
        print(hachi[1])
    else:
        print('-1')

Submission status: Wrong Answer

Solution code:
import math

a,b = map(int, input().split())
t = 1
x = False
y = False
z = False

while t <= 10000:
    c = math.floor(t * 0.08)
    
    if c == a:
        x = True
    else:
        x = False
        
    if c == b:
        y = True
    else:
        y = False
        
    if x and y:
        print(t)
        z = True
        break
        
    t = t + 1

if z == False:
    print('-1')

Submission status: Wrong Answer

Solution code:
import math 
A,B = map(int,input().split()) 
# print(A/0.08,B/0.1)
price = []
x = int(A/0.08)
# print(x,y)
y = int(B/0.1)
for i in range(min(x,y),10001):
	if math.floor(i*0.08) == math.floor(i*0.1):
		price.append(i)	
		break
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
if len(price) == 0:
	print(-1)
else:
	print(min(price))

Submission status: Wrong Answer

Solution code:
import math 
A,B = map(int,input().split()) 
# print(A/0.08,B/0.1)
price = []
x = int(A/0.08)
y = int(B/0.1)
# print(x,y)
if x> y:
	for i in range(y,10001):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
			break
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
elif x==y:
	price.append(math.floor(A/0.08))
else:
	for i in range(x,10001):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)
			break	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
	# if math.floor(i*0.08) == math.floor(i*0.1): 
	# 	price.append(i)
if len(price) == 0:
	print(-1)
else:
	print(min(price))

Submission status: Wrong Answer

Solution code:
import math 
A,B = map(int,input().split()) 
# print(A/0.08,B/0.1)
price = []
x = math.ceil(B/0.1)
y = math.ceil(A/0.08)
if x> y:
	for i in range(y,10000):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
elif x==y:
	price.append(math.floor(A/0.08))
else:
	for i in range(x,10000):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
	# if math.floor(i*0.08) == math.floor(i*0.1): 
	# 	price.append(i)
if len(price) == 0:
	print(-1)
else:
	print(min(price))

Submission status: Wrong Answer

Solution code:
import math 
A,B = map(int,input().split()) 
# print(A/0.08,B/0.1)
price = []
x = math.ceil(B/0.1)
y = math.ceil(A/0.08)
if x> y:
	for i in range(y,10000):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)
			break	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
elif x==y:
	price.append(math.floor(A/0.08))
else:
	for i in range(x,10000):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
			break
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
	# if math.floor(i*0.08) == math.floor(i*0.1): 
	# 	price.append(i)
if len(price) == 0:
	print(-1)
else:
	print(min(price))

Submission status: Wrong Answer

Solution code:
import math 
A,B = map(int,input().split()) 
# print(A/0.08,B/0.1)
price = []
x = math.ceil(B/0.1)
y = math.ceil(A/0.08)
if x> y:
	for i in range(y,x+1):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
elif x==y:
	price.append(math.floor(A/0.08))
else:
	for i in range(x,y+1):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
	# if math.floor(i*0.08) == math.floor(i*0.1): 
	# 	price.append(i)
if len(price) == 0:
	print(-1)
else:
	print(min(price))

Submission status: Wrong Answer

Solution code:
import math 
A,B = map(int,input().split()) 
# print(A/0.08,B/0.1)
price = []
x = math.floor(B/0.1)
y = math.floor(A/0.08)
if x> y:
	for i in range(y,x+1):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
elif x==y:
	price.append(math.floor(A/0.08))
else:
	for i in range(x,y+1):
		if math.floor(i*0.08) == math.floor(i*0.1):
			price.append(i)	
		# print(i, math.floor(i*0.08),math.floor(i*0.1))
	# if math.floor(i*0.08) == math.floor(i*0.1): 
	# 	price.append(i)
if len(price) == 0:
	print(-1)
else:
	print(min(price))

Submission status: Wrong Answer

Solution code:
import math
A, B = list(map(int, input().split()))

amax = math.ceil((A + 1) / 8 * 100) - 1
amin = math.ceil(A / 8 * 100)
bmax = math.ceil((B + 1) / 10 * 100) - 1
bmin = math.ceil(int(B / 10 * 100))

if amin > bmax or bmin > amax:
    print(-1)
else:
    print(int(max(amin, bmin)))

Submission status: Wrong Answer

Solution code:
import math
A, B = list(map(int, input().split()))

amax = math.ceil((A + 1) / 8 * 100) - 1
amin = math.ceil(int(A / 8 * 100))
bmax = math.ceil((B + 1) / 10 * 100) - 1
bmin = math.ceil(int(B / 10 * 100))

if amin > bmax or bmin > amax:
    print(-1)
else:
    print(int(max(amin, bmin)))

Submission status: Wrong Answer

Solution code:
a, b = input().split()

for i in range(10):
    a_f = float(a + '.' + str(i))
    b_f = float(b + '.' + str(i))
    if a_f / 0.08 and b_f / 0.1:
        print(int(a_f / 0.08))
        break
else:
    print('-1')

Submission status: Wrong Answer

Solution code:
# coding:utf-8


from math import ceil, floor

import numpy as np


def genLsLeftAndRight(a, b, c, d):
    if a <= b <= c <= d:
        return [b, c]
    elif a <= b <= d <= c:
        return [b, d]
    elif a < c < b < d:
        return [None, None]
    elif b <= a <= c <= d:
        return [a, c]
    elif b <= a <= d <= c:
        return [a, d]
    elif b < d < a < c:
        return [None, None]



def genAns(lsLeftAndRight):
    left, right = lsLeftAndRight
    if None in lsLeftAndRight:
        return -1
    if ceil(left) > floor(right):
        return -1
    else:
        return int(ceil(left))

strInput = input()
A, B = np.array(strInput.split(' ')).astype(int)
a, b, c, d = A/0.08, B/0.1, (A+1)/0.08, (B+1)/0.1
print(genAns(genLsLeftAndRight(a, b, c, d)))

Submission status: Wrong Answer

Solution code:
from math import floor
a, b = map(int, input().split())
a1, b1 = floor(a/0.08), floor(b/0.1)
if a1 == b1:
    print(a1)
else:
    if a1 < b1:
        f = 0
        a2 = float(a+1)
        while a < a2:
            a += 0.01
            if floor(a/0.08) == floor(b/0.1):
                f = 1
                break
        if f:
            print(floor(a/0.08))
        else:
            print(-1)
    else:
        f = 0
        b2 = float(b+1)
        while b < b2:
            b += 0.01
            if floor(b / 0.1) == floor(a / 0.08):
                f = 1
                break
        if f:
            print(floor(b / 0.1))
        else:
            print(-1)

Submission status: Wrong Answer

Solution code:
from math import floor
a, b = map(int, input().split())
a1, b1 = floor(a/0.08), floor(b/0.1)
if a1 == b1:
    print(a1)
else:
    if a1 < b1:
        f = 0
        a2 = round(a+1, 3)
        while a < a2:
            a = round(a+0.01, 3)
            if floor(a/0.08) == floor(b/0.1):
                f = 1
                break
        if f:
            print(floor(a/0.08))
        else:
            print(-1)
    else:
        f = 0
        b2 = round(b+1, 3)
        while b < b2:
            b = round(b+0.01, 3)
            if floor(b / 0.1) == floor(a / 0.08):
                f = 1
                break
        if f:
            print(floor(b / 0.1))
        else:
            print(-1)

Submission status: Wrong Answer

Solution code:
from math import floor
a, b = map(int, input().split())
a1, b1 = floor(a/0.08), floor(b/0.1)
if a1 == b1:
    print(a1)
else:
    if a1 < b1:
        f = 0
        a2 = a+1
        while a < a2:
            a = round(a+0.01, 3)
            if floor(a/0.08) == floor(b/0.1):
                f = 1
                break
        if f:
            print(floor(a/0.08))
        else:
            print(-1)
    else:
        f = 0
        b2 = b+1
        while b < b2:
            b = round(b+0.01, 3)
            if floor(b / 0.1) == floor(a / 0.08):
                f = 1
                break
        if f:
            print(floor(b / 0.1))
        else:
            print(-1)

Submission status: Wrong Answer

Solution code:
from math import floor
a, b = map(int, input().split())
a1, b1 = floor(a/0.08), floor(b/0.1)
if a1 == b1:
    print(a1)
else:
    if a1 < b1:
        f = 0
        a2 = a+1
        while a < a2:
            a = round(a+0.1, 2)
            if floor(a/0.08) == floor(b/0.1):
                f = 1
                break
        if f:
            print(floor(a/0.08))
        else:
            print(-1)
    else:
        f = 0
        b2 = b+1
        while b < b2:
            b = round(b+0.1, 2)
            if floor(b / 0.1) == floor(a / 0.08):
                f = 1
                break
        if f:
            print(floor(b / 0.1))
        else:
            print(-1)

Submission status: Wrong Answer

Solution code:
import math
import sys
 
a,b = map(int,input().split())
 
a_min = math.ceil(a/0.08)
a_max = math.floor((a+1)/0.08)
 
b_min = math.ceil(b/0.1)
b_max = math.floor((b+1)/0.1)
 
a_list = list(range(a_min,a_max+1))
b_list = list(range(b_min,b_max+1))
 
 
for num in a_list:
    if num in b_list:
        print(num)
        sys.exit()
 
print('-1')

Submission status: Wrong Answer

Solution code:
import math
import sys
 
a,b = map(int,input().split())
 
a_min = math.ceil(a/0.08)
a_max = math.floor((a+1)/0.08)
 
b_min = math.ceil(b/0.1)
b_max = math.floor((b+1)/0.1)
 
a_list = list(range(a_min,a_max+1))
b_list = list(range(b_min,b_max+1))
 
 
for num in a_list:
    if num in b_list:
        print(num)
        sys.exit()
 
print(-1)

Submission status: Wrong Answer

Solution code:
import math
import sys

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

a_min = math.floor(a/0.08)
a_max = math.ceil((a+1)/0.08)

b_min = math.floor(b/0.1)
b_max = math.ceil((b+1)/0.1)

a_list = list(range(a_min,a_max+1))
b_list = list(range(b_min,b_max+1))


for num in a_list:
    if num in b_list:
        print(num)
        sys.exit()

print(-1)

Submission status: Wrong Answer

Solution code:
import math
A, B = map(int, input().split())
result = 'No'
for i in range(1, 101):
    eight = math.floor(i * 0.08)
    ten = math.floor(i * 0.10)
    if eight == A and ten == B:
        print(i)
        result = 'Yes'
        break
if result == 'No':
    print(-1)

Submission status: Wrong Answer

Solution code:
a=input()
(n,m)=a.split(" ")
n=int(n)
m=int(m)
k=n/0.08
k=int(k)
j=m/0.1
j=int(j)
if n==m:
    if k-j>=1:
        print(k)
    else:
        print(int("-1"))
else:
  if k==j:
     print(k)
  else:
      print(int("-1"))

Submission status: Wrong Answer

Solution code:
a=input()
(n,m)=a.split(" ")
n=int(n)
m=int(m)
k=n/0.08
k=int(k)
j=m/0.1
j=int(j)
if n==m:
    if k==j+5:
        print(k)
    else:
        print(int("-1"))
else:
  if k==j:
     print(k)
  else:
      print(int("-1"))

Submission status: Wrong Answer

Solution code:
a=input()
(n,m)=a.split(" ")
n=int(n)
m=int(m)
k=n/0.08
k=int(k)
j=m/0.1
j=int(j)
if n==m:
    if k==j+5:
        print(k)
    else:
        print("-1")
else:
  if k==j:
     print(k)
  else:
      print("-1")

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
a_min = int(a/0.08)
a_max = int((a+1)/0.08)
b_min = int(b/0.1)
b_max = int((b+1)/0.1)
if a_min >= b_min and a_min <= b_max:
    print(int(a_min))
elif b_min >= a_min and b_min <= a_max:
    print(int(b_min))
else:
    print(-1)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

o = 0.08
t = 0.10

aa = {i for i in range(int(a/o),int((a/o)+12.5)+1)}
bb = {i for i in range(int(a/o),int((a/o)+12.5)+1)}

if min(aa&bb):
	print(min(aa&bb))
else:
	print(-1)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

o = 0.08
t = 0.1

aa = {i for i in range(int(a / o),int((a + 1) / o)+1)}
bb = {i for i in range(int(a / o),int((a + 1) / o)+1)}

if min(aa&bb):
	print(min(aa&bb))
else:
	print(-1)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

o = 0.08
t = 0.1

aa = {i for i in range(int(a / o),int((a + 0.999) / o))}
bb = {i for i in range(int(a / o),int((a + 0.999) / o))}

if min(aa&bb):
	print(min(aa&bb))
else:
	print(-1)

Submission status: Wrong Answer

Solution code:
# 158-C
a, b = map(int, input().split())
ans = -1
for i in range(1, 101):
    if int(i/100*8) == a and int(i/10) == b:
        ans = i
        break
print(ans)

Submission status: Wrong Answer

Solution code:
import sys
A,B = map(int,input().split(" "))

sentinel1 = 0
N = 1
while sentinel1 < A:
    sentinel1 = int(N * 0.08)
    sentinel2 = int(N * 0.1)
    if sentinel1 == A:
        if sentinel2 == B:
            print(N)
            sys.exit()
    N = N + 1

print(-1)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

o = 0.08
t = 0.1

x = a / o
y = b / t

if x > y:
	lst = [i for i in range(int(y-1),int(x+1))]
else:
	lst = [i for i in range(int(x-1),int(y+1))]

for i in lst:
	if int(i * o) == a and int(i*t)==b:
		print(i)
		exit()

print(-1)

Submission status: Wrong Answer

Solution code:
A, B = (int(i) for i in input().split())  
A_p_min = A/0.08
A_p_max = (A+1)/0.08
B_p_min = B/0.1
B_p_max = (B+1)/0.1
cnt = -1
for i in range(int(A_p_max-0.001),int(A_p_min)-1,-1):
    for j in range(int(B_p_max-0.001),int(B_p_min)-1,-1):
        #print(j)
        if i == j:
            cnt = i
print(cnt)

Submission status: Wrong Answer

Solution code:
A, B = (int(i) for i in input().split())  
A_p_min = A/0.08
A_p_max = (A+1)/0.08
B_p_min = B/0.1
B_p_max = (B+1)/0.1
cnt = -1
for i in range(int(A_p_max)-1,int(A_p_min)-1,-1):
    #print(i)
    for j in range(int(B_p_max)-1,int(B_p_min)-1,-1):
        if i == j:
            cnt = i
print(cnt)

Submission status: Wrong Answer

Solution code:
A, B = (int(i) for i in input().split())  
A_p_min = A/0.08
A_p_max = A/0.08 + 7
B_p_min = B/0.1
B_p_max = B/0.1 + 9
cnt = -1
for i in range(int(A_p_max),int(A_p_min)-1,-1):
    #print(i)
    for j in range(int(B_p_max),int(B_p_min)-1,-1):
        if i == j:
            cnt = i
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

list = []
if 100*a%8:
  x=int(a/0.08)+1
else:
  x=int(a/0.08)

if 100*(a+1)%8:
    y=int((a+1)/0.08)-1
else:
    y=int((a+1)/0.08)

    
for i in range(x, y+1):
    if b/0.1 <= i <(b+1)/0.1:
        list.append(i)

        
list = sorted(list)
if list:
    print(list[0])
else:
    print('-1')

Submission status: Wrong Answer

Solution code:
import math
text = list(map(int, input().split()))

reply = -1
i = 0
while math.floor(i * 0.08) <= text[0] and math.floor(i * 0.1) <= text[1]:
    print([i, math.floor(i * 0.08), math.floor(i * 0.1)])
    if math.floor(i * 0.08) == text[0] and math.floor(i * 0.1) == text[1]:
        reply = i
        break
    i += 1
print(reply)

Submission status: Wrong Answer

Solution code:
from math import *
x8, x10 = map(int, input().split())
min8 = x8 * 100 / 8
max8 = (x8 + 1) * 100 / 8
min10 = x10 * 100 / 10
max10 = (x10 + 1) * 100 / 10

if max8 < min10:
  print(-1)
else:
  print(int(max(min10, min8)))

Submission status: Wrong Answer

Solution code:
A, B = map(int,input().split())
Arate = 0.08
Brate = 0.10

flag = False
for i in range(1,1000):
  tmpA = int(i*Arate)
  tmpB = int(i*Brate)

  if tmpA == A and tmpB == B:
    print(i)
    flag = True
    break


if flag is False: print(-1)

Submission status: Wrong Answer

Solution code:
A, B = map(int,input().split())
eps = 10.0**(-16)
Arate = 0.08
Brate = 0.10

flag = False
for i in range(1,1000):
  tmpA = int((i+eps)*Arate)
  tmpB = int((i+eps)*Brate)

  if tmpA == A and tmpB == B:
    print(i)
    flag = True
    break


if flag is False: print(-1)

Submission status: Wrong Answer

Solution code:
# coding: utf-8

import math
import decimal

# 標準入力 <int><int>
A, B = map(int, input().split())

tax8 = decimal.Decimal('0.08')
tax10 = decimal.Decimal('0.1')

Amin = math.ceil(decimal.Decimal(A / tax8))

Bmin = math.ceil(decimal.Decimal(B / tax10))

ans = -1

isFin = False

for i in range(8):
    for j in range(10):
        if Amin + i == Bmin + j:
            ans = Amin + i
            isFin = True
            break
    if isFin:
        break

print(ans)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())

ans = -1

for p in range(13, 1350):
    if p * 0.08 == A and p * 0.1 == B:
        ans = p
        break

print(ans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
bans = -1
j = 1
while bans != j:
    if j * 8 // 100 == a:
        bans = j
    else:
        j = j + 1
if bans * 10 // 100 == b:
    print(bans)
else:
    print('-1')

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
bans = -1
j = 1
while bans != j:
    if j * 8 // 100 == a:
        bans = j
    else:
        j = j + 1
if bans * 10 // 100 == b:
    print(bans)
else:
    print('-1')
    print(bans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
for i in range(1,1001):
	if i * 8 == a * 100 and int(i * 0.1) == b:
		print(i)
		break
else:
	print(-1)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
for i in range(1001):
	if i * 8 == a * 100 and int(i * 0.1) == b:
		print(i)
		break
else:
	print(-1)

Submission status: Wrong Answer

Solution code:
import math
a,b=list(map(int,input().split()))
ans=-1
for i in range(math.floor(a*100/8)+1,math.floor((a+1)*100/8)+1):
  if math.floor(i*10/100)==b:
    ans=i
    break
print(ans)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

o = 0.08
t = 0.1

x = a / o
y = b / t

if x > y:
	lst = [i for i in range(int(y),int(x+1))]
else:
	lst = [i for i in range(int(x),int(y+1))]

for i in lst:
	if int(i * o) == a and int(i*t)==b:
		print(i)
		exit()

print(-1)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if int(1.25*a)!=b:
	print(-1)
else:
	x=1
	while not (x*8==100*a and int(x*0.1)==b):
		x+=1
	print(x)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if int(1.25*a)!=b:
	print(-1)
else:
	x=0
	while not (x*8==100*a and int(x*0.1)==b):
		x+=1
	print(x)

Submission status: Wrong Answer

Solution code:
import math
a,b=list(map(int,input().split()))
ans=-1
for i in range(math.floor(a*100/8),math.floor((a+1)*100/8)+1):
  if math.floor(i*10/100)==b:
    ans=i
    break
print(ans)

Submission status: Wrong Answer

Solution code:
import math
a,b=list(map(int,input().split()))
ans=-1
for i in range(math.floor(a*100/8),math.floor((a+1)*100/8)):
  if math.floor(i*10/100)==b:
    ans=i
    break
print(ans)

Submission status: Wrong Answer

Solution code:
import math
a,b=list(map(int,input().split()))
ans=-1
for i in range(math.floor(a*100/8),math.ceil(a*100/8)):
  if math.floor(i*10/100)==b:
    ans=i
    break
print(ans)

Submission status: Wrong Answer

Solution code:
import math
a,b=list(map(int,input().split()))
ans=-1
for i in range(math.floor(a*100/8),10000):
  if math.floor(i*10/100)==b:
    ans=i
    break
print(ans)

Submission status: Wrong Answer

Solution code:
a, b = list(map(int,input().split()))

for p in range(1000):
  if int((p + 1) * 0.08) == a and int((p + 1) * 0.1) == b:
    print(p)
    break
  if p == 999:
    print('-1')

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())

if A == 4/5*B:
  ans = 10*B
  print(ans)
elif A == B: #Bは、切り捨てられているから正確ではないからAを使う
  hhh = 25/2*A
  print(hhh)
else:
  print('-1')

Submission status: Wrong Answer

Solution code:
# coding: utf-8
# Your code here!

x, y = list(map(int,(input().split())))


for a in range(1,101):
    if int(a * 0.1) == y:
        if int(a * 0.08) == x:
            print(a)
            exit()
print(-1)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())

if A == 4/5*B:
  ans = 10*B
  print(ans)
else:
  print('-1')

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

list = []
if 100*a%8:
  x=int(a/0.08)+1
else:
  x=int(a/0.08)

for i in range(x, int((a+1)/0.08)+1):
    if b/0.1 <= i <(b+1)/0.1:
        list.append(i)

        
list = sorted(list)
if list:
    print(list[0])
else:
    print('-1')

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
p,q,r,s = int(a//0.08),int((a+1)//0.08),int(b//0.10),int((b+1)//0.10)
a_lis = []
b_lis = []
for i in range(p+1,q+1):
  a_lis.append(i)
for i in range(r+1,s+1):
  b_lis.append(i)
c = list((set(a_lis) & set(b_lis)))
if c:
  print(c[0])
else:
  print(-1)

Submission status: Wrong Answer

Solution code:
def tax_increase(a,b):
    t8  = 0.08
    t10 = 0.1
    
    al = [ i for i in range(a*10,(a+1)*10,1)]
    bl = [ i for i in range(b*10,(b+1)*10,1)]

    atx8 = list(map(lambda x: int(x/t8) ,al))
    btx10 = list(map(lambda x: int(x/t10) ,bl))

    #print(atx8)
    #print(btx10)
    
    for i in atx8:
        if i in btx10:
            return i/10
        else:
            pass
    return -1

if __name__ == '__main__':
    a,b = map(int,input().split())
    ans = int(tax_increase(a,b))
    print(ans)

Submission status: Wrong Answer

Solution code:
def tax_increase(a,b):
    t8  = 0.08
    t10 = 0.1
    
    al = [a * 10 + i for i in range(0,10,1)]
    bl = [b * 10 + i for i in range(0,10,1)]

    atx8 = list(map(lambda x: int(x/t8) ,al))
    btx10 = list(map(lambda x: int(x/t10) ,bl))

    #print(atx8)
    #print(btx10)
    
    for i in atx8:
        if i in btx10:
            return i/10
        else:
            pass
    return -1

if __name__ == '__main__':
    a,b = map(int,input().split())
    ans = int(tax_increase(a,b))
    print(ans)

Submission status: Wrong Answer

Solution code:
def tax_increase(a,b):
    t8  = 0.08
    t10 = 0.1
    
    al = [a + (i / 10) for i in range(0,10,1)]
    bl = [b + (i / 10) for i in range(0,10,1)]

    atx8 = list(map(lambda x: int(x/t8) ,al))
    btx10 = list(map(lambda x: int(x/t10) ,bl))

    #print(atx8)
    #print(btx10)
    
    for i in atx8:
        if i in btx10:
            return i
        else:
            pass
    return -1

if __name__ == '__main__':
    a,b = map(int,input().split())
    ans = int(tax_increase(a,b))
    print(ans)

Submission status: Wrong Answer

Solution code:
def tax_increase(a,b):
    t8  = 0.08
    t10 = 0.1
    
    al = [a + (i / 10) for i in range(0,10,1)]
    bl = [b + (i / 10) for i in range(0,10,1)]

    atx8 = list(map(lambda x: x/t8 ,al))
    btx10 = list(map(lambda x: x/t10 ,bl))

    for i in atx8:
        if i in btx10:
            return i
        else:
            pass
    return -1

if __name__ == '__main__':
    a,b = map(int,input().split())
    ans = int(tax_increase(a,b))
    print(ans)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
i=0
while i<1000:
    X=int(i*0.08)
    Y=int(i*0.10)
    if A==X and B==Y:
        break
    i=i+1
if i==1000:
    i=-1
    print(i)
else:
    print(i)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
i=0
while True:
    X=int(i*0.08)
    Y=int(i*0.10)
    if A==X and B==Y:
        break
    i=i+1
if i==100:
    i=-1
    print(i)
else:
    print(i)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
i=0
while i > 0:
    X=int(i*0.08)
    Y=int(i*0.10)
    if A==X and B==Y:
        break
    i=i+1
if i==100:
    i=-1
    print(i)
else:
    print(i)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
i=0
while i <100:
    X=int(i*0.08)
    Y=int(i*0.10)
    if A==X and B==Y:
        break
    i=i+1
if i==100:
    i=-1
    print(i)
else:
    print(i)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
i=0
while i <100:
    X=int(i*0.08)
    Y=int(i*0.10)
    if A==X and B==Y:
        break
    i=i+1
if i==100:
    print("-1")
else:
    print(i)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

list = []
if 100*a%8:
  x=int(a/0.08)+1
else:
  x=int(a/0.08)

for i in range(x, int((a+1)/0.08)+1):
    if b/0.1 <= i <(b+1)/0.1:
        list.append(i)
        list = sorted(list)
        print(list[0])
        exit()

print('-1')

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

list = []
for i in range(int(a/0.08), int((a+1)/0.08)+1):
    if b/0.1 <= i <(b+1)/0.1:
        list.append(i)
        list = sorted(list)
        print(list[0])
        exit()

print('-1')

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())

print ((B-A)*50)

Submission status: Wrong Answer

Solution code:
from __future__ import print_function

import sys

import re
import array
import copy
import functools
import operator

import math
import string
import fractions
from fractions import Fraction
from fractions import gcd
# fractions.gcd() を用いること
# math.log2()はatcoderでは対応していない．留意せよ．

import collections
import itertools
import bisect

import random
import time

import heapq
from heapq import heappush
from heapq import heappop
from heapq import heappushpop
from heapq import heapify
from heapq import heapreplace
from queue import PriorityQueue as pq
from queue import Queue

from itertools import accumulate

from collections import deque
from collections import Counter

from operator import mul
from functools import reduce

input = sys.stdin.readline


def eprint(*args, **kwargs):
    print(*args, file=sys.stderr, **kwargs)
    return


def lcm(n, m):
    return int(n * m / gcd(n, m))


def coprimize(p, q):
    common = fractions.gcd(p, q)
    return (p // common, q // common)


def combinations_count(n, r):
    r = min(r, n - r)
    numer = reduce(mul, range(n, n - r, -1), 1)
    denom = reduce(mul, range(1, r + 1), 1)
    return numer // denom


def main():
    a,b = map(int,input().strip().split())
    # 100*a//8 <= x < 100*(a+1)//8
    # range(100*a//8,100*(a+1)//8)
    x=100*a//8
    while 100*a <= 8*x < 100*(a+1):
        if 100*b <= 10*x < 100*(b+1):
            print(x)
            return
        x+=1
    print(-1)
if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
from __future__ import print_function

import sys

import re
import array
import copy
import functools
import operator

import math
import string
import fractions
from fractions import Fraction
from fractions import gcd
# fractions.gcd() を用いること
# math.log2()はatcoderでは対応していない．留意せよ．

import collections
import itertools
import bisect

import random
import time

import heapq
from heapq import heappush
from heapq import heappop
from heapq import heappushpop
from heapq import heapify
from heapq import heapreplace
from queue import PriorityQueue as pq
from queue import Queue

from itertools import accumulate

from collections import deque
from collections import Counter

from operator import mul
from functools import reduce

input = sys.stdin.readline


def eprint(*args, **kwargs):
    print(*args, file=sys.stderr, **kwargs)
    return


def lcm(n, m):
    return int(n * m / gcd(n, m))


def coprimize(p, q):
    common = fractions.gcd(p, q)
    return (p // common, q // common)


def combinations_count(n, r):
    r = min(r, n - r)
    numer = reduce(mul, range(n, n - r, -1), 1)
    denom = reduce(mul, range(1, r + 1), 1)
    return numer // denom


def main():
    a,b = map(int,input().strip().split())
    # 100*a//8 <= x < 100*(a+1)//8
    # range(100*a//8,100*(a+1)//8)
    x=100*a//8
    while 100*a//8<=x<100*(a+1)/8:
        if 100*b <= 10*x < 100*(b+1):
            print(x)
            return
        x+=1
    print(-1)
if __name__ == '__main__':
    main()