In technical fest there were too many volunteers for technical head of the department thought to take a quick test, by which the lucky volunteers will be selected for the technical fest. So they have to solve a question for it.
Question is to find the Lucky number, Lucky number is a largest number made up of only digits 2,3 and 5 such that the count for each digit is divisible by the number obtained by multiplication of remaining two digits. You are provided with the number N and you have to output the lucky number of N digits. If no lucky number exists for the given N output -1.
So help volunteers to pass the test.
First line of the input contains an integer T denoting number of test cases. The description of T test cases follows. The only line of each test case contains the integer N denoting the length of Handsome Number.
For each test case output the Handsome number or -1 if no Handsome Number exist.
1 <= T <= 100
1 <= N <= 100
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.