#include<bits/stdc++.h>
using namespace std;

#define ll long long int
#define pb push_back
#define mp make_pair
#define ff first
#define ss second
#define pii pair<int,int>
#define gap " "
#define ok cout<<"ok"<<endl
#define DBG(a) cerr<< "Line "<<__LINE__ <<" : "<< #a <<" = "<<(a)<<endl
#define fastio {ios_base::sync_with_stdio(false);cin.tie(NULL);}

int main()
{
    
    ll n,m,ans=0;
    cin>>n>>m;
    ll ar[m+2];
    for(ll i=1;i<=m;i++)
        cin>>ar[i];
    sort(ar+1,ar+m+1);
    ll mn=1e12;
    vector<ll>v;
    if(m==0)
    {
        cout<<1<<endl;
        return 0;
    }
    if(ar[1]!=1)
    {
        v.pb(ar[1]-1);
        mn=min(mn,ar[1]-1);
    }
    if(ar[m]!=n)
    {
        v.pb(n-ar[m]);
        mn=min(mn,n-ar[m]);
    }
    for(ll i=2;i<=m;i++)
    {
        ll d=ar[i]-ar[i-1]-1;
        if(!d) continue;
        v.pb(d);
        mn=min(mn,d);
    }
    for(ll i=0;i<v.size();i++)
    {
        if(v[i]%mn==0)
            ans+=(v[i]/mn);
        else
            ans+=(v[i]/mn)+1;
    }
    cout<<ans<<endl;
    return 0;
}
#include <unordered_map>
#include <unordered_set>
#include <algorithm>
#include <iostream>
#include <iostream>
#include <fstream>
#include <numeric>
#include <cstring>
#include <cassert>
#include <string>
#include <vector>
#include <queue>
#include <deque>
#include <cmath>
#include <set>
#include <map>
#include <functional>
#include <bitset>
#include <iomanip>
#include <stack>
#include <list>
#include <cstdint>
#include <chrono>
#include <hash_map>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/detail/standard_policies.hpp>

using namespace __gnu_pbds;
using namespace std;

#define     lp(i, a, n)       for(ll i=a;i<n;i++)
#define     lp2(i, n, a)      for(ll i=a-1;i>=n;i--)
#define     all(arr, n)      arr,arr+n
#define     allv(v)         (v).begin(),(v).end()
#define     rallv(v)        (v).rbegin(),(v).rend()
#define     m_p             make_pair
#define     ll              long long
#define     pii             pair<ll,ll>
#define     vi              vector<int>
#define     vll             vector<ll>
#define     vii             vector<pii>
#define     sz(x)           (int)x.size()
#define     pb              push_back
#define     endl            '\n'
#define     Endl            '\n'
#define     f               first
#define     s               second
#define     mem(dp, n)       memset(dp,n,sizeof dp)
#define     ordered_set     tree<int,null_type,less<int>,rb_tree_tag,tree_order_statistics_node_update>

template<typename T>
void max_self(T &a, T b) { a = max(a, b); }

template<typename T>
void min_self(T &a, T b) { a = min(a, b); }

int dx[] = {1, 0, -1, 0, -1, -1, 1, 1};
int dy[] = {0, 1, 0, -1, -1, 1, -1, 1};
int KnightX[] = {2, 1, -1, -2, -2, -1, 1, 2};
int KnightY[] = {1, 2, 2, 1, -1, -2, -2, -1};

void fast() {
    std::ios_base::sync_with_stdio(0);
    cin.tie(NULL);
    cout.tie(NULL);
}

vector<string> vec_splitter(string s) {
    s += ',';
    vector<string> res;
    while(!s.empty()) {
        res.push_back(s.substr(0, s.find(',')));
        s = s.substr(s.find(',') + 1);
    }
    return res;
}
void debug_out(
        vector<string> __attribute__ ((unused)) args,
        __attribute__ ((unused)) int idx,
        __attribute__ ((unused)) int LINE_NUM) { cerr << endl; }
template <typename Head, typename... Tail>
void debug_out(vector<string> args, int idx, int LINE_NUM, Head H, Tail... T) {
    if(idx > 0) cerr << ", "; else cerr << "Line(" << LINE_NUM << ") ";
    stringstream ss; ss << H;
    cerr << args[idx] << " = " << ss.str();
    debug_out(args, idx + 1, LINE_NUM, T...);
}
#define debug(...) debug_out(vec_splitter(#__VA_ARGS__), 0, __LINE__, __VA_ARGS__)
const int MAXN = 2e5 + 1, oo = 0x3f3f3f3f, MOD = 1e9 + 7;
const long double PI = acos(-1), eps = 1e-9;

void solve() {
    int n,m;
    cin>>n>>m;
    ll arr[m+3]={};
    lp(i,1,m+1)
        cin>>arr[i];
    arr[m+1]=n+1;
    sort(all(arr,m+2));
    ll mn=1e9,res=0;
    lp(i,1,m+2){
        if(arr[i]==arr[i-1]+1)continue;
        min_self(mn,arr[i]-arr[i-1]-1);
    }
    lp(i,1,m+2){
        res+=(arr[i]-arr[i-1]-1+mn-1)/mn;
    }
    cout<<res<<endl;
}

int main() {
#ifndef ONLINE_JUDGE
    freopen("input.in", "r", stdin);
    freopen("output.txt", "w", stdout);
#endif
    fast();
    int t = 1;
    //cin>>t;
    while (t--)
        solve();
    return 0;
}