import Control.Arrow (second)
import Data.List
import qualified Data.Vector.Unboxed as V
import qualified Data.ByteString.Char8 as B

solve :: V.Vector Int -> Int
solve xs = V.sum xs - V.length xs

main = do
  Just n <- fmap fst . B.readInt <$> B.getLine
  xs <- V.unfoldrN n (fmap (second B.tail) . B.readInt) <$> B.getLine
  print $ solve xs

