What A* Solves
A* is a classical algorithm for solving shortest-path search problems in weighted graphs by combining path cost and heuristic guidance.
Conceptually, it extends graph search by evaluating each state through the function f(n) = g(n) + h(n), where g(n) is the cost accumulated so far and h(n) is an estimate of the remaining cost to the goal.
Instead of exploring nodes only by distance from the source, A* prioritizes states that appear most promising, often reducing unnecessary exploration while preserving optimality under suitable conditions on the heuristic.