P9477 [_-0 C] Number Guessing
Background
Little $\mathfrak{f}$ and little $\mathfrak{g}$ are playing a number guessing game, but because the wind is too loud, they cannot hear what the other person says clearly.
Description
The judge randomly selects an integer $x$ uniformly from the interval $[1,n]$. Your task is to guess this number.
Each time, you may give an integer $y$ in $[1,n]$ and ask for the comparison between $y$ and $x$. You can ask at most $q$ times.
However, for some reason, the judge has a $p\%$ probability of making a mistake.
Specifically:
- If $y=x$, then the judge returns `=`.
- If $y\ne x$, and this is already the $q$-th query, then the judge returns `!`.
- **After getting either of the above two results, you should stop querying.**
- If $y>x$, then with probability $(100-p)\%$ the judge returns `>`, and with probability $p\%$ it returns `
Input Format
Before you start querying, one line with three integers $n,p,q$ separated by spaces.
For each query, one line with one character, which must be one of `=`, `!`, `>`, `
Output Format
For each query, output one line with one integer in $[1,n]$.
Explanation/Hint
**Explanation for Sample $1$:**
At this time, the status of this test point is `AC`.
**Explanation for Sample $2$:**
When $x=37,y=50$, we have $y>x$. There is a $10\%$ probability to output `