Roughly the idea is:
We associate a number with every possible path.
In classical mechanics, there is only one correct path.
In quantum mechanics, there is no single correct path, and we sum over all paths. The classical path is the path with the largest contribution to the sum.