main = do
    n <- readLn :: IO Int
    a <- readLn :: IO Int
    b <- readLn :: IO Int
    c <- readLn :: IO Int
    d <- readLn :: IO Int
    e <- readLn :: IO Int
    let ls = [a,b,c,d,e]
    let m = minimum ls
    let wait = n `div` m
    print $ wait + 5
