remove testing code
trace path by 1-dimension array,small bug
shortest path bug fixed
add comment