After you helped to save last year's Tic-Tac-Toe World Championships, you were given a grant to write a new tic-tac-toe AI to determine the best move to play.
A Tic-Tac-Toe board looks like the following. Every square can be empty, filled with an X, or filled with a O (capital letter 'o').
Player X has won if they have three X's in a row. Player O wins if they can do the same with the O's. A row can be horizontal, vertical, or diagonal.
Given the player whose turn it is, and a board where there is one winning move for that player, can you output the row and column where that player should play?
The first line of the input is either X or O, representing the player whose turn it is.
The next three lines each have $3$ characters. Each of these lines represents a row on the board. Each character in a line represents a square in that row. This means you have $3$ rows and $3$ columns just like a normal Tic-Tac-Toe board.
Each square in the board contains either an X, O (that's a capital letter, not a number), or E. An X or O represents markings made by the players while E represents an empty square.
Input Restrictions
Output two space-separated integers representing the row and the column where the player should play. Note, the rows and columns are $1$-indexed, so if the player should play in the top left corner, then you should output "$1$ $1$".