Simulated Annealing Algorithm Python Code