#C7109. Taco Grid Game Winner
Taco Grid Game Winner
Taco Grid Game Winner
You are given an N x N grid along with its elements. Although the grid numbers are provided, the winner of the game is determined solely based on the parity of N.
The rules are very simple:
- If N is even, then Player 1 wins.
- If N is odd, then Player 2 wins.
Note: The grid elements are given for completeness but are not used to determine the outcome.
Formally, if we denote N as the grid size, then the winner is determined as follows:
\( \text{Winner} = \begin{cases} \text{Player 1} & \text{if } N \text{ is even} \\ \text{Player 2} & \text{if } N \text{ is odd} \end{cases} \)
inputFormat
The first line of input contains a single integer N representing the size of the grid.
This is followed by N lines, each containing N space separated integers representing the grid elements.
Note: The grid numbers are provided for compatibility, but only the value of N is needed to determine the winner.
outputFormat
Output a single line containing the name of the winning player, which is either "Player 1" or "Player 2" based on the following criteria:
- If N is even, output "Player 1".
- If N is odd, output "Player 2".
3
1 2 3
4 5 6
7 8 9
Player 2