{"trustable":true,"sections":[{"title":"","value":{"format":"MD","content":"\u003ch3\u003e Read problems statements in \u003ca target\u003d\"_blank\" href\u003d\"https://www.codechef.com/download/translated/SNCKPA16/mandarin/NDIFFPAL.pdf\"\u003eMandarin Chinese\u003c/a\u003e, \u003ca target\u003d\"_blank\" href\u003d\"https://www.codechef.com/download/translated/SNCKPA16/russian/NDIFFPAL.pdf\"\u003eRussian\u003c/a\u003e and \u003ca target\u003d\"_blank\" href\u003d\"https://www.codechef.com/download/translated/SNCKPA16/vietnamese/NDIFFPAL.pdf\"\u003eVietnamese\u003c/a\u003e as well.\u003c/h3\u003e\r\n\r\n\r\n\u003cp\u003eA palindrome is a string that reads same in both directions: forwards and backwards. For example, the strings \u003cb\u003eradar\u003c/b\u003e and \u003cb\u003enoon\u003c/b\u003e are palindromes, whereas the string \u003cb\u003echef\u003c/b\u003e is not a palindrome as being read backwards is becomes equal to \u003cb\u003efehc\u003c/b\u003e, which is not equal to \u003cb\u003echef\u003c/b\u003e.\u003c/p\u003e\r\n\r\n\u003cp\u003eLet\u0027s say that the pair of indices \u003cb\u003e(i, j)\u003c/b\u003e \u003ci\u003edenotes a palindrome\u003c/i\u003e in some string \u003cb\u003eS\u003c/b\u003e iff \u003cb\u003ei ≤ j\u003c/b\u003e and the substring starting at the \u003cb\u003ei\u003c/b\u003e-th character and ending at the \u003cb\u003ej\u003c/b\u003e-th character of \u003cb\u003eS\u003c/b\u003e is a palindrome.\u003c/p\u003e \r\n\r\n\u003cp\u003eGiven an integer \u003cb\u003eN\u003c/b\u003e. Your task is to construct a string \u003cb\u003eS\u003c/b\u003e such that there are exactly \u003cb\u003eN\u003c/b\u003e different pairs \u003cb\u003e(i, j)\u003c/b\u003e that denotes a palindrome.\u003c/p\u003e\r\n\r\n\u003ch3\u003eInput\u003c/h3\u003e\r\n\u003cp\u003eThe first line of the input contains an integer \u003cb\u003eT\u003c/b\u003e denoting the number of test cases. The description of \u003cb\u003eT\u003c/b\u003e test cases follows.\u003c/p\u003e\r\n\u003cp\u003eThe first line of each test case contains a single integer \u003cb\u003eN\u003c/b\u003e denoting the sought number of pairs that denote palindrome. \u003c/p\u003e\r\n\r\n\u003ch3\u003eOutput\u003c/h3\u003e\r\n\u003cp\u003eFor each test case, output a single line containing a string \u003cb\u003eS\u003c/b\u003e, consisting of lowecase Latin letters, and having exactly \u003cb\u003eN\u003c/b\u003e distinct palindrome-denoting pairs. If there\u0027s a few such strings, output any one.\u003c/p\u003e\r\n\r\n\u003cp\u003eIf such string \u003cb\u003eS\u003c/b\u003e doesn\u0027t exist, output \u003cb\u003e-1\u003c/b\u003e instead of it.\u003c/p\u003e\r\n\r\n\u003ch3\u003eConstraints\u003c/h3\u003e\r\n\u003cul\u003e\r\n\u003cli\u003e\u003cb\u003e1\u003c/b\u003e ≤ \u003cb\u003eT\u003c/b\u003e ≤ \u003cb\u003e100\u003c/b\u003e\u003c/li\u003e\r\n\u003cli\u003e\u003cb\u003e1\u003c/b\u003e ≤ \u003cb\u003eN\u003c/b\u003e ≤ \u003cb\u003e10\u003csup\u003e4\u003c/sup\u003e\u003c/b\u003e\u003c/li\u003e\r\n\u003c/ul\u003e\r\n\r\n\u003ch3\u003eExample\u003c/h3\u003e\r\n\u003cpre\u003e\u003cb\u003eInput:\u003c/b\u003e\r\n\u003ctt\u003e3\r\n6\r\n7\r\n2\r\n\u003c/tt\u003e\r\n\u003cb\u003eOutput:\u003c/b\u003e\r\n\u003ctt\u003enoon\r\nradar\r\nab\u003c/tt\u003e\u003c/pre\u003e\r\n\r\n\u003ch3\u003eExplanation\u003c/h3\u003e\r\n\u003cp\u003e\u003cb\u003eExample case 1.\u003c/b\u003e In the string \"noon\", the pairs that denote a palindrome are (1-indexed): \u003cb\u003e(1, 1), (1, 4), (2, 2), (2, 3), (3, 3), (4, 4)\u003c/b\u003e.\u003c/p\u003e\r\n\u003cp\u003e\u003cb\u003eExample case 2.\u003c/b\u003e In the string \"radar\", the pairs that denote a palindrome are (1-indexed): \u003cb\u003e(1, 1), (1, 5), (2, 2), (2, 4), (3, 3), (4, 4), (5, 5)\u003c/b\u003e.\u003c/p\u003e\r\n\u003cp\u003e\u003cb\u003eExample case 3.\u003c/b\u003e In the string \"ab\", the pairs denoting a palindrome are : \u003cb\u003e(1, 1), (2, 2)\u003c/b\u003e\u003c/p\u003e"}}]}