Submission #743216

#TimeUsernameProblemLanguageResultExecution timeMemory
743216vjudge1Lightning Rod (NOI18_lightningrod)C++17
0 / 100
2072 ms262144 KiB
#include <iostream> #include <unordered_map> using namespace std; inline void read(long long &x) { x = 0; char ch = getchar_unlocked(); while (ch & 16) { x = (x << 3) + (x << 1) + (ch & 15); ch = getchar_unlocked(); } } int main () { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); unordered_map<int,int> ma; long long n, a, b, sum = 0; read(n); for(long long i = 0;i < n;++i) { read(a); read(b); if(ma[a] == 0) { ma[a] = 1; sum++; } } cout << sum; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...