/*
	may God of speed-forces be with us !!

	--problem isnt, life is empty;
	--problem is, life is full of emptiness;
		a non-strugling pupil coder !!
*/

#include "bits/stdc++.h"
using namespace std;
#define pb push_back
#define F first
#define S second
//#define biGinf 9e+18
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
#define inpv(v) for(auto &x:v) cin>>x
#define otpv(v) for(auto &x:v) cout<<x<<nwl
#define otpv2(v) for(auto &x:v) cout<<x<<" "
#define CASES int tt;cin>>tt; while(tt--)
#define for0(i,n) for(int i=0; i<n; i++)
#define for1(i,n) for(int i=1; i<=n; i++)
#define forr(i,r,n) for(int i=r; i<=n; i++)
#define forj(j,n) for(int j=n; j>=0; j--)
#define forx(x,v) for(auto &x:v)
#define sz(v) (int)(v).size()
#define rz(n) resize(n)
#define vec(x) vector < x >
#define vvim(n,m,v) vvi v(n, vi(m))
using int64 = long long;
using vi = vector < int >;
using vi64 = vector < int64 >;
using mii = map <int , int >;
using vvi = vector < vi >;
using pii = pair < int , int >;
using vpii = vector < pii >;
const int inf = 2e9 + 7;
const char nwl = '\n';
const int mxx = 1e6 + 3;

int64 sumV(vi &v) {
	int64 s = 0;
	for (int x : v) {
		s += (int64)x;
	}
	return s;
}

int gcd(int a, int b) {
	if (!b) return a;
	return gcd(b, a % b);
}

bool powerOf2(int n) {
	if (n & (n - 1)) return 0;
	return 1;
}


//const int64 biGinf = 9e+18;
//const string yo = "Yes\n", no = "No\n";

int64 ceil2(int64 a, int64 b) {
	int64 d = a / b;
	if (a % b ) d += 1;
	return d;
}

int32_t main() {
	ios_base::sync_with_stdio(false);
	cin.tie(NULL);
	//ur code
	int64 n, m;
	cin >> n >> m;
	vi64 v(m);
	inpv(v);
	sort(all(v));

	int64 ans = 0;

	if (n == m) {
		ans = 0;
	} else if (!m) {
		ans = 1;
	} else {
		int64 c = 0, p = n;
		for0(i, m) {
			int64 z = v[i] - c - 1ll;
			if (z > 0)
				p = min(p, z);
			c = v[i];
		}

		int64 z = n - v[m - 1];
		if (z > 0) {
			p = min(p, z);
		}

		c = 0;

		for0(i, m) {
			int64 x = ceil2((v[i] - c - 1ll) , p);
			c = v[i];
			ans += x;
		}

		int64 x = ceil2((n - c), p);
		ans += x;
	}
	cout << ans << nwl;



	return 0;
}


#include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define rep(i,n) for (int i = 0; i < (n); ++i)
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }

int main(){
  int n, m; cin >> n >> m;
  vector<int> a(m+2);
  rep(i,m) cin >> a[i+1];
  a.back() = n+1;
  sort(a.begin(), a.end());
  
  int k = n;
  rep(i,m+1){
    int x = a[i+1] - a[i] - 1;
    if(x > 0) chmin(k, x);
  }
  
  int ans = 0;
  rep(i,m+1){
    int x = a[i+1] - a[i] - 1;
    if(x > 0) ans += (x + k-1)/k;
  }
  
  cout << ans << endl;
}