At every iteration, the heuristic value is calculated for every possible postion of the queen in a particular column for each column. The queen position with the lowest heuristic value is then chosen to move to. If multuple positions have the same value, a random position is chosen
Question:
Hint