Use Priority Queue to implement the heuristic k-nn search