#P10352. [PA 2024] Kto wygrał?
[PA 2024] Kto wygrał?
Background
PA 2024 1C
Problem Description
This problem is translated from PA 2024 Round 1 Kto wygrał?.
Algosia and Bajtek like to compete in PA. In the online contest, there are tasks to solve, and each task can give from to points. Contestants are ranked by total score. If the total scores are equal, the contestant who got points on more tasks is ranked higher. If there is still a tie, the contestant who got points on more tasks is ranked higher, and so on. If the contestants cannot be distinguished in this way, they are declared tied.
Algosia and Bajtek remember all their scores from last year’s contest, but they do not remember… who won. Can you help them write a program that reads their results and tells whose rank is higher?
Input Format
The first line contains integers in the range , representing Algosia’s score on each task.
The second line also contains integers in the range , representing Bajtek’s score on each task.
Output Format
Print one word on one line: Algosia or Bajtek, the name of the winner. If there is a tie, print remis (Polish for a draw).
10 10 7 10 10 10 10 10 10 10 10 10 0 10 4 10 10 10
10 10 10 10 10 10 10 10 10 10 10 10 4 3 4 10 10 10
Algosia
Hint
Although both Algosia and Bajtek have a total score of points, according to PA rules Algosia is ranked higher.
Translated by ChatGPT 5