#include "bits/stdc++.h"
#pragma warning(disable:4996)
using namespace std;
#define int long long
#define rep(i,n) for(int i=0;i<n;i++)
const int mod = 1000000007;
const long long inf = 1ll << 61;
typedef pair<int, int> P;
typedef pair<int, P>PP;
int a[100006];
signed main() {
	int n; cin >> n;
	rep(i, n)cin >> a[i];
	set<int>S;
	rep(i, n)S.insert(a[i]);
	cout << S.size() << endl;
}
