main :: IO ()
main = do
  [a, b] <- map read . words <$> getLine
  putStrLn $ maybe "IMPOSSIBLE" show $ solve a b

solve :: Int -> Int -> Maybe Int
solve a b
  | odd (a + b) = Nothing
  | otherwise   = Just $ (a + b) `div` 2
