#include<bits/stdc++.h>
using namespace std;
#define INF 1e9
#define MOD 1000000007
#define foru(i,a,b) for(int i=(a); i<(b); i++)
#define forue(i,a,b) for(int i=(a); i<=(b); i++)
#define forb(i,n) for(int i=n-1; i>=0; i--)
#define forall(it,v) for(auto it=v.begin();it!=v.end();++it)
#define pb push_back
#define fst first
#define snd second
#define pt(x) cout << x << "\n"
#define sz(c) ((int)c.size())
#define add(a, b, w) edges[a].pb(make_pair(b, w))
typedef pair<int,int> iai;
typedef long long int ll;

int a[200010];


int main(){

    //freopen("input.in", "r", stdin);
    //cin.tie(0);
    ios::sync_with_stdio(false);
    cin.tie(0);

    int n,m;
    cin >> n >> m;
    if(!m) pt(1);
    else {
        vector<int> v(m);


        foru(i, 0, m) {
            cin >> v[i];
        }
        sort(v.begin(), v.end());
        priority_queue<int, vector<int>, greater<int>> pq;
        int i = 0;
        int ant = 0;
        while (i < m) {
            if (v[i] - (ant + 1) > 0) {
                pq.push(v[i] - (ant + 1));
            }
            ant = v[i];
            i++;

        }
        if (n - v[m - 1] > 0) {
            pq.push(n - v[m - 1]);
        }
        if (pq.empty()) pt(0);
        else {
            double menor = pq.top();
            pq.pop();
            ll r = 1;
            while (!pq.empty()) {
                double act = pq.top();
                r += (int) ceil(act / menor);
                pq.pop();
            }
            pt(r);
        }
    }
}
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;

int main(){
  long long n,m;
  cin >> n >> m;
  vector<long long> a(m+2);
  for (long long i = 0; i < m; i++){
    cin >> a[i];
  }
  a[m] = 0;
  a[m+1] = n+1;
  sort(a.begin(),a.end());
  long long k = 1000000000;
  vector<long long> white(m+1);
  for (long long i = 0; i < m+1; i++){
    long long temp = a[i+1]-a[i]-1;
    if (temp > 0){
      k = min(k,temp);
    }
    white[i] = temp;
  }
  int res = 0;
  for (auto n : white){
    res += n / k;
    if (n % k != 0){
      res++;
    }
  }
  cout << res << endl;
}