Probability One
Number guessing is a popular game between elementary-school kids. Teachers encourage pupils to play the game as it enhances their arithmetic skills, logical thinking, and following-up simple procedures. We think that, most probably, you too will master in few minutes. Here’s one example of how you too can play this game: Ask a friend to think of a number, let’s call it n_0.
Then:
Ask your friend to compute n_1 = 3·n_0 and to tell you if n1 is even or odd.
If n_1 is even, ask your friend to compute n_2 = n_1/2. If, otherwise, n_1 was odd then let your friend compute n_2 = (n_1+1)/2.
Now ask your friend to calculate n_3 = 3·n_2.
Ask your friend to tell tell you the result of n_4 = n_3/9. (n_4 is the quotient of the division operation. In computer lingo, "/" is the integer-division operator.)
Now you can simply reveal the original number by calculating n_0 = 2·n_4 if n_1 was even, or n_0 = 2·n_4+1 otherwise.
Here’s an example that you can follow: If n_0 = 37, then n_1 = 111 which is odd. Now we can calculate n_2 = 56, n_3= 168, and n_4 = 18, which is what your friend will tell you. Doing the calculation 2·n_4+1 = 37 reveals n_0.
Input
Your program will be tested on one or more test cases. Each test case is made of a single positive number (0 < n_0 < 1, 000, 000).
The last line of the input file has a single zero (which is not part of the test cases).
Output
For each test case, print the following line:
k. B Q
Where k is the test case number (starting at one,) B is either "even" or "odd" (without the quotes) depending on your friend’s answer in step 1. Q is your friend’s answer to step 4.
Note: There is a blank space before B.