procedure simulated-annealing begin initialize N to 1 select a current point, currentNode, at random update NodesGenerated bestNode <- currentNode print repeat select a new point, newNode, in the neighborhood of currentNode using the twoInterchange method with random cities update NodesGenerated if evaluation(newNode) < evaluation(currentNode) currentNode <- newNode else if random[0,1] < temp currentNode <- newNode if evaluation(currentNode) < evaluation(bestNode) bestNode <- currentNode print until N = 2000 end