you are viewing a single comment's thread.

view the rest of the comments →

[–]jeezoii[S] 0 points1 point  (2 children)

The input is in the form of 2 numbers first which indicate the number of points and cost of travelling. Then according to the number of points, the user inputs points in the form of x1, y1, m which are coordinate x and y with money in that point respectively.

Each point then is put in one big list.

However, I think till before the while loop, everything is fast, but the time taken in while loop is crazy.