generate palindromes in descending order, then check if they can be factored into two n-digit numbers. start from the largest possible palindrome and work downwards.
for each palindrome, try to find factors by checking divisors from the largest n-digit number down. early termination when factors become too small.
optimization
generate palindromes efficiently by mirroring the first half. check divisibility starting from largest possible factor to minimize iterations.
complexity
O(10^(2n)) worst case, but optimizations make it much faster in practice. O(1) space.