Basically, it will ask you to look at one number and sum up the two digits, and subtract the sum from the number. If you have 31 in mind, the sum is 4, so the final number is 27. Now just click on the ball, it will show the symbol represented by number 27.
This only works when you really think hard, the man can either capture your brainwave or track the direction of your eye sight to figure out the number in your mind.
If you can figure out what is happening, leave a comment.