module Main where
    import Data.List
    import Control.Monad
    
    main = do
        {-
        n <- getLine
        lines<-getLines (read n ::Int)
        -}        
        inputs<-getInputs        
        print ( foldr (*) 1 (map pred inputs))
        
        
    read' s = read s ::Integer

    getInputs = do
        line <- getLine
        let inputs = map read' (words line)
        return inputs

    getLines n = do
        lines <- (replicateM n getLine)
        return lines

    getGCD::Integer->Integer->Integer
    getGCD m n 
        | m < n = (getGCD n m)
        | n == 0 = m
        | otherwise = getGCD (mod m n) n

    getLCM::Integer->Integer->Integer
    getLCM m n = div (m * n) (getGCD m n)
   