You play a game on a directed graph with N nodes. Each edge has a score (can be negative). Find the maximum score when traveling between node and node N.
If you can achieve arbitrarily high scores, print .
Constraints: , . Negative edges exist, so this is not a standard shortest-path problem. You need to handle negative weights and detect if a positive cycle (in the original graph) affects the path from to .