#include <bits/stdc++.h>
using namespace std;
#define int long long
#define REPF(i, a, n) for (int i = (a); i < (int)(n); i++)
#define REP(i, n) REPF(i, 0, n)
#define ALL(x) begin(x),end(x)
#define SZ(x) (int)(x.size())

signed main() {
    int N, M;
    cin >> N >> M;
    vector<int> A(M);
    REP(i, M) cin >> A[i];
    
    int ans = 0;
    REP(i, M) {
        if (A[i] > M) {
            ans++;
        }
    }
    cout << ans << endl;
    return 0;
}
