main :: IO () main = interact $ show . solve . map read . words solve :: [Integer] -> Int solve [a, b] = if b `div` a < 500 then 1 else 2