aboutsummaryrefslogtreecommitdiff
path: root/02_sorting_and_searching/distinct_numbers_1621.cpp
blob: 9c39aa371491f0e026aea2cd992aacef7bb98120 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#include <iostream>
#include <set>

int main() {
	int n, x;
	std::set<int> s;
	std::cin >> n;
	for (int i = 0; i < n; i++) {
		std::cin >> x;
		s.insert(x);
	}
	std::cout << s.size() << "\n";
}

Generated with cgit - Back to sebastiano.tronto.net