I tried so many combinations and permutations of what could be answer the description does not help me much and the solutions does not help me understand why is that working...
Can somebody help me? problem link --> https://mirror.codeforces.com/contest/2095/problem/B









Think outside the box : )
There is no standard logic to solve this it is a simple but tricky observation drop the ball outside of the box-limits and it will hit the ground for sure! Thus guaranteeing victory in every round. If you print any number within limits of the box the simulation is then random and it could end up any way, mostly a loss.