#include<algorithm>
#include<iostream>
#include<cstring>
#include<cstdio>
using namespace std;
int n,m;
int ans;
int a[500005];
int main()
{
	cin>>n>>m;
	for(int i=1;i<=m;i++)
		cin>>a[i];
	sort(a+1,a+m+1);
	int k=1e9+7;
	int lst=0;
	a[++m]=n+1;
	for(int i=1;i<=m;i++)
		{
		if(a[i]-lst-1!=0)
			k=min(k,a[i]-lst-1);
		lst=a[i];
		}
	lst=0;
	for(int i=1;i<=m;i++)
		{
		if(a[i]-lst-1!=0)
			ans+=(a[i]-lst-1+k-1)/k;
		lst=a[i];
		}
	cout<<ans<<endl;
	return 0;
}
#include <bits/stdc++.h>
#pragma GCC target("avx2")
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")
#define ll long long
#define ALL(a) (a).begin(),(a).end()
#define rep(i,n) for(int i=0;i<(n);i++)
#define rrep(i,n) for(int i=n-1;i>=0;i--)
#define Pii pair<int,int>
#define Pll pair<long long,long long>
#define fout(num) cout << fixed << setprecision(20) << (num) << endl
template<typename T1,typename T2> inline void chmin(T1 &a,T2 b){if(a>b) a=b;}
template<typename T1,typename T2> inline void chmax(T1 &a,T2 b){if(a<b) a=b;}
//vector<vector<ll>> dp(n,vector<ll>(n))
//2-dim:vector<vector<Type>> vv(n, vector<Type>(m, d));
//3-dim:vector<vector<vector<Type>>> vvv(n, vector<vector<Type>>(m, vector<Type>(l, d)));

using namespace std;

signed main(){
    std::cin.tie(nullptr);
    std::ios_base::sync_with_stdio(false);
    int n,m; cin >> n >> m;
    vector<int> a(m+2);
    a[0]=0;
    rep(i,m) cin >> a[i+1];
    if(m==0){
        cout << 1 << endl;
        return 0;
    }
    a[m+1]=n+1;
    sort(ALL(a));
    int mi=1e9;
    rep(i,m+1){
        if(a[i]+1!=a[i+1]&&a[i]!=a[i+1]) chmin(mi,a[i+1]-a[i]-1);
    }
    int ans=0;
    rep(i,m+1){
        ans += (a[i+1]-a[i]-1+mi-1)/mi;
        //cout << (a[i+1]-a[i]-1+mi-1)/mi << endl;
    }
    
    cout << ans << endl;
    return 0;
}
// g++ main.cpp -o main.out && ./main.out