#include<cstdio>
#include<algorithm>
using namespace std;
const int INF =1000000000;
struct Station{
double p, dis;//单位油价,距起点距离
}sta[510];
bool cmp(Station a, Station b){
return a.dis < b.dis;
}
int main(){
double Cmax, D, Davg;
int n;
while(scanf("%lf%lf%lf%d...