#include<algorithm>
#include<iostream>
#include<cmath>
using namespace std;
int main()
{
	long n,a[5];
	cin>>n;
	for(int i=0;i<5;i++)cin>>a[i];
	sort(a,a+5);
	cout<<(4+n/a[0]+(n%a[0]>0))<<endl;
	return 0;
}