The Wizard announced, "I will set each of you free as soon as you can tell me the number on your forehead. Nobody is allowed to communicate with any other person in any way. You get only one guess each."
Tom, Dick, and Harry sat in silence for several hours, filling up pages of calculations. Getting bored, the Wizard said, "Hey, I had thought you were clever guys. All right, I'll give each one of you just one hint. Tom, the square root of your number is a palindrome. Dick, the square root of your number is not a palindrome. Harry, any two adjacent digits of your number differ at most by 3."
And then the Wizard's castle echoed, "GOT IT !!!" as they all shouted together.
What were the numbers on each person's forehead?