Vampire Numbers

A number v = x ∗ y with an even number (n) of digits formed by multiplying a pair of n/2-digit numbers (where the digits are taken from the original number in any order) x and y together is known as vampire number. Pairs of trailing zeros (both the numbers have a trailing zero) are not allowed. If v is a vampire number then x and y are called its “fangs.” Examples of 4-digit vampire numbers include

  1. 21 × 60 = 1260 2) 15 × 93 = 1395 3) 35 × 41 = 1435 4) 30 × 51 = 1530 5) 21 × 87 = 1827 6) 27 × 81 = 2187 7) 80 × 86 = 6880 In this program you will have to find all the 4, 6 and 8 digit even vampire numbers. Input The input file contains maximum ten lines of input. Each line contains a single integer n whose value is 4, 6 or 8. Input is terminated by end of file. Output For each input n produce all the n-digit vampire numbers that are even in ascending order. Print a blank line after the output for each set of input. Sample Input 4 4 Sample Output 1260 1530 6880 1260 1530 6880