Next Special Palindrome Number
Scan upward from n and accept the first number that reads the same both ways and has each digit d appearing exactly d times.
Scan upward from n and accept the first number that reads the same both ways and has each digit d appearing exactly d times.