program tax_increase
  implicit none
  integer :: a, b, x, n, i
  read(*,*) a, b
  n = 10*b
  do i = 0, 9
    x = n+i
    if (2*x/25 == a) then
      write(*,'(i0)') x
      stop
    end if
  end do
  write(*,'(i0)') -1
end program tax_increase