Q28.Alex and Elena play a game. Each round score is `[x, y]`, where `x` is Alex's score and `y` is Elena's score. The procedure `findGameWinner(S)` returns `winner = 1` if Alex wins, `winner = 2` if Elena wins, and `winner = 0` for a draw. Which procedure(s) correctly identify the winner?
Save
Check
Details
Q28
3 Dec 2023
Q28.Alex and Elena play a game. Each round score is `[x, y]`, where `x` is Alex's score and `y` is Elena's score. The procedure `findGameWinner(S)` returns `winner = 1` if Alex wins, `winner = 2` if Elena wins, and `winner = 0` for a draw. Which procedure(s) correctly identify the winner?