UVALive 5009 Error Curves
F(x)是一个凸函数(convex function)
用三分(ternary search)可求最小值点
另外,EPS设置成>1e-9会WA
#include <bits/stdc++.h>
using namespace std;
const int MAX_N = 10000 + 10;
const double EPS = 1e-9;
int n;
int...
原创
2018-05-19 17:15:07 ·
187 阅读 ·
0 评论