Changed the iterate method in AStar to run()