Nearest neighbor (NN) algorithm is a search algorithm that finds the shortest path is to find the next point or path will reach close to the current address, such as if we will travel to A city B and city C is the starting point for A route from the nearest town and the town is A B NN algorithm it will calculate and select a path to the city instead of going to town B C before the behavior of this algorithm does not guarantee that the route is the shortest path or not, but, on average, to find the shortest route, then puzzled tapas is at 25%.