제출 #72818

#제출 시각아이디문제언어결과실행 시간메모리
72818funcsr커다란 상품 (IOI17_prize)C++17
20 / 100
4 ms556 KiB
#include "prize.h" #include <iostream> #include <vector> #include <algorithm> #include <queue> #include <cmath> #include <cassert> using namespace std; #define rep(i,n)for (int i=0; i<(n); i++) #define all(x) (x).begin(), (x).end() #define pb push_back #define _1 first #define _2 second #define INF 1145141919 typedef pair<int, int> P; int find_best(int N) { int lo = 0, hi = N-1; while (hi-lo>=1) { int mid = (lo+hi)/2; vector<int> ret = ask(mid); if (ret[0]+ret[1] == 0) return mid; if (ret[0]>0) hi = mid-1; else lo = mid+1; } return lo; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...