Ping Paja Pong
All submissions for this problem are available.### Read problem statements in [Hindi](http://www.codechef.com/download/translated/LTIME73/hindi/PAJAPONG.pdf), [Bengali](http://www.codechef.com/download/translated/LTIME73/bengali/PAJAPONG.pdf), [Mandarin Chinese](http://www.codechef.com/download/translated/LTIME73/mandarin/PAJAPONG.pdf), [Russian](http://www.codechef.com/download/translated/LTIME73/russian/PAJAPONG.pdf), and [Vietnamese](http://www.codechef.com/download/translated/LTIME73/vietnamese/PAJAPONG.pdf) as well. Chef and Paja are bored, so they are playing an infinite game of ping pong. The rules of the game are as follows: - The players play an infinite number of games. At the end of each game, the player who won it scores a point. - In each game, one of the players *serves*. Chef serves in the first game. - After every $K$ points are scored (regardless of which players scored them), i.e. whenever $K$ games have been played since the last time the serving player changed, the player that serves in the subsequent games changes: if Chef served in the game that just finished, then Paja will serve in the next game and all subsequent games until the serving player changes again; if Paja served, then Chef will serve. The players got a little too caught up in the game and they forgot who is supposed to serve in the next game. Will you help them determine that? So far, Chef has scored $X$ points and Paja has scored $Y$ points. ### Input - The first line of the input contains a single integer $T$ denoting the number of test cases. The description of $T$ test cases follows. - The first and only line of each test case contains three space-separated integers $X$, $Y$ and $K$. ### Output For each test case, print a single line containing the string `"Chef"` if Chef is supposed to serve next or `"Paja"` otherwise (without quotes). ### Constraints - $1 \le T \le 50$ - $0 \le X, Y \le 10^9$ - $1 \le K \le 10^9$ ### Subtasks **Subtask #1 (100 points):** original constraints ### Example Input ``` 3 1 3 3 5 7 2 38657 76322 564 ``` ### Example Output ``` Paja Chef Paja ``` ### Explanation **Example case 1:** Chef served for the first three games, after that Paja started serving. He only served in one game, so he is supposed to serve next.
|Tags||ltime73, taran_1407, thesitzr|
|Time Limit:||1 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.6, PYPY, CS2, PAS fpc, PAS gpc, RUBY, PHP, GO, NODEJS, HASK, rust, SCALA, swift, D, PERL, FORT, WSPC, ADA, CAML, ICK, BF, ASM, CLPS, PRLG, ICON, SCM qobi, PIKE, ST, NICE, LUA, BASH, NEM, LISP sbcl, LISP clisp, SCM guile, JS, ERL, TCL, kotlin, PERL6, TEXT, SCM chicken, PYP3, CLOJ, R, COB, FS|
Fetching successful submissions
If you are still having problems, see a sample solution here.