Official algorithmic problem description and constraints.
In a football match, a penalty shootout is used to determine the winner if the score is tied after regulation and extra time. Each team takes turns attempting five penalty kicks.
Team A has scored π goals in 3 turns while team B has scored π goals in 4 turns.
Determine if it's possible for the penalty shootout to end with equal score after both teams have taken all 5 of their penalty kicks.
Detailed video explanations, mathematical intuition, and clean C++ implementation code.