import Control.Monad
import Control.Applicative
import Data.List


main :: IO()
main = do
  n <- readLn :: IO Int
  lst <- replicateM 5 readLn :: IO [Int]
  let mi = minimum lst
  print $ 5 + (n + mi - 1) `div` mi -1
