21 lines
293 B
Python
21 lines
293 B
Python
|
from math import ceil
|
||
|
|
||
|
def main():
|
||
|
x, y = [int(i) for i in input().split()]
|
||
|
|
||
|
if x==y:
|
||
|
return x
|
||
|
|
||
|
c = ceil(x / (2*y))
|
||
|
if x < y:
|
||
|
return -1
|
||
|
|
||
|
if c > (x+y)/(2*x):
|
||
|
print(c, (x+y)/(2*x))
|
||
|
c = ceil((x+y)/(2*x))
|
||
|
|
||
|
return (x+y)/(2*c)
|
||
|
|
||
|
|
||
|
print(main())
|