UVa1615 - Highway

出處:https://onlinejudge.org/index.php?option=onlinejudge&Itemid=8&page=show_problem&problem=4490

解題策略:找出每一個地點(x,y),距離D以內出口投影到X軸的範圍

x1=x-sqrt(D*D-y*y), x2=x+sqrt(D*D-y*y)

使用x1由小到大排序這些區間,區間重疊設定為同一個出口,沒有重疊則新增出口