import Data.List
import Data.Char
import qualified Data.ByteString.Char8 as BS8
 
main :: IO ()
main = do
    [a, b] <- unfoldr (BS8.readInt . BS8.dropWhile isSpace) <$> BS8.getLine

    putStrLn $ if abs ((a - b) `mod` 2) == 0
        then show $ abs (abs (a - b) `div` 2 - maximum [a, b])
        else "IMPOSSIBLE"
