#include <bits/stdc++.h>
using namespace std;
int n, a[1007], mak[1007], i, m;
void khoitao() {
  for (i = 0; i <= m; ++i) mak[i] = 0;
}
int main(int argc, char** argv) {
  cin >> n;
  for (i = 1; i <= n; ++i) cin >> a[i];
  m = a[1];
  for (i = 1; i <= n; ++i) {
    m = max(m, a[i]);
  }
  for (i = 1; i <= n; ++i) mak[a[i]] += 1;
  int dem = 0;
  for (i = 1; i <= m; ++i)
    if (mak[i] != 0) dem++;
  cout << dem;
  return 0;
}
