제출 #1039215

#제출 시각아이디문제언어결과실행 시간메모리
10392150npataTriangles (CEOI18_tri)C++17
0 / 100
1 ms348 KiB
#include<bits/stdc++.h> #include "trilib.h" using namespace std; int n; bool is_on_convex_hull(int i) { int mx = i == 0 ? 1 : 0; for(int j = 0; j<n; j++) { if(j == i || j == mx) continue; if(is_clockwise(i, mx, j)) mx = j; } for(int j = 0; j<n; j++) { if(j == i || j == mx) continue; if(is_clockwise(i, mx, j)) return false; } return true; } int32_t main() { n = get_n(); int ans = 0; for(int i = 0; i<n; i++) { ans += is_on_convex_hull(i); } give_answer(ans); return 0; }
#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...