module Main where

main = interact $ printer . solver . parser
int = read :: String -> Int

parser = map int . words

printer = unlines .(:[]).show

solver [n,a,b] = if ans < 0 then 0 else ans
  where
    minv = a + b + a * (n-2)
    maxv = a + b + b * (n-2)
    ans  = maxv - minv + 1

