Function j(n) converts a positive integer n into a list of related integers. The related integers each have the same number of digits, but each digit is either the same, or one more, or one less than the digit in n which has the same location.
Restrictions:
* at least one digit must be changed,
* a leading 1 cannot be changed into a leading zero,
* there is no wrapping around: a 0 can only become 0 or 1; a 9 can only become 9 or 8.
1. If n has d digits, what is a lower bound and upper bound on the length of the list that j(n) produces?
What is the smallest perfect square which can be jiggled to produce:
2. another square?
3. a cube?
4. both another square and a cube?
5. two squares and two cubes?