#include #include #include #include #include #include #include #include #include #include #define _USE_MATH_DEFINES #include #include #include #include #include using namespace std; #include using namespace atcoder; #define rep(i,x) for(ll i=0;i P; const ll INF = 1e17; const ll MAX = 4000001; const long double eps = 1E-14; ll max(ll a, ll b) { if (a > b) { return a; } return b; } ll min(ll a, ll b) { if (a > b) { return b; } return a; } ll gcd(ll a, ll b) { if (b == 0) { return a; } if (a < b) { return gcd(b, a); } return gcd(b, a % b); } ll lcm(ll a, ll b) { return a / gcd(a, b) * b; } struct edge { ll id; ll fr; ll to; ll d; }; using mint = modint; typedef vector vll; typedef vector > vvll; typedef vector>> vvvll; typedef vector vmint; typedef vector> vvmint; typedef vector>> vvvmint; vmint f, finv, inv; void cominit(ll N) { ll MOD = modint::mod();//デフォルトが998244353に注意 f.assign(N + 1, 1); finv.assign(N + 1, 1); inv.assign(N + 1, 1); inv[1] = 1; repn(i, N) { f[i] = f[i - 1] * i; if (i > 1)inv[i] = -inv[MOD % i] * (MOD / i); finv[i] = finv[i - 1] * inv[i]; } } mint com(ll a, ll b) { if (a < 0 || b < 0 || a < b) { return 0; } return f[a] * finv[b] * finv[a - b]; } ///////////////////////////////////// int main() { cout << fixed << setprecision(10); ll N, M; cin >> N >> M; vll B(M); rep(i, M)cin >> B[i]; double ans = INF; ll sum = 0; for (ll i = M - 1; i >= 0; i--) { sum += N - B[i]; double now = (double)(M) / (double)(M-i) +(double)(sum) / (double)(M - i); now += B[0] - 1; //cout << now << endl; ans = min(ans, now); } ans = min(ans, (double)(N - 1)); cout << ans << endl; }