import std.stdio, std.string, std.range, std.conv, std.array, std.algorithm, std.math, std.typecons;

void main() {
    const N = readln.chomp.to!long;
    const xs = 5.iota.map!(_ => readln.chomp.to!long).array;
    writeln(4 + cast(long)ceil(cast(double)N / xs.reduce!min));
}

