Submission #743169

#TimeUsernameProblemLanguageResultExecution timeMemory
743169vjudge1Lightning Rod (NOI18_lightningrod)C++17
0 / 100
2082 ms174636 KiB
#include <bits/stdc++.h> #define x first #define y second using namespace std; const int N = 1e7 + 1; pair<int,int> arr[N]; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); int n,ans=0; cin >> n; for(int i=1;i<=n;i++) cin >> arr[i].x >> arr[i].y; set<int> s; for(int i=1;i<=n;i++) s.insert(arr[i].x); cout << s.size(); return 0; }

Compilation message (stderr)

lightningrod.cpp: In function 'int main()':
lightningrod.cpp:10:11: warning: unused variable 'ans' [-Wunused-variable]
   10 |     int n,ans=0; cin >> n;
      |           ^~~
#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...