A spy number is a natural number whose sum of digits is equal to the product of its digits. For example, 123 is a spy number because . (All one-digit natural numbers are spy numbers, since each such number has only one digit.) One day, Muaz started writing spy numbers in his notebook. He noticed that he wrote two-digit spy numbers, three-digit spy numbers, four-digit spy numbers, five-digit spy numbers and six-digit spy numbers. Find the sum of the maximum and minimum values among and .