Through the dark forests, crossing seven seas and thirteen rivers, Pepe has finally reached the mythical Island of Bika. There he found a cave. Some old saying says that whoever finds a cave on the Island of Bika and enters it never comes back alive, but Pepe is known as the most courageous in his village. So, he decides to enter it. There he finds a locked chest and a note beside it. The entrance immediately closes but fortunately Pepe had come with a torch. Pepe starts reading the note:
You are given two positive integers $$$n$$$ and $$$x$$$. There is an array $$$a$$$ consisting of $$$m$$$ non-negative integers. Let $$$m$$$ be the size of the array $$$a$$$. For each $$$i$$$ ($$$1 \le i \le m$$$), $$$a_i$$$ is the base of the $$$i$$$-th summand, and $$$x$$$ is the common exponent of every summand.
Formally,
$$$$$$n = a_1^x + a_2^x + \dots + a_m^x$$$$$$
Your task is to find the minimum possible value of $$$m$$$, i.e. the minimum possible size of $$$a$$$.
Pepe has to enter the answer and the array $$$a$$$ into the chest, which contains a smart lock system. It is said that the Island of Bika was once the greatest in technology.
Help Pepe get the treasure and escape the cave.
Constraints
Subtasks
| Subtask | Points | Add. constraints |
| $$$1$$$ | $$$7$$$ | $$$x=1$$$ |
| $$$2$$$ | $$$8$$$ | $$$2^x \gt n$$$ |
| $$$3$$$ | $$$8$$$ | $$$m=2$$$ |
| $$$4$$$ | $$$10$$$ | $$$x=2;1 \le n \le 100$$$ |
| $$$5$$$ | $$$14$$$ | $$$ 1 \le n \le 1000$$$ |
| $$$6$$$ | $$$25$$$ | $$$ 1 \le n \le 10^5;2\le x \le 3$$$ |
| $$$7$$$ | $$$28$$$ | No additional constraints |
Each test file contains multiple test cases. The first line of the input contains the number of test cases $$$T$$$. Then, for each test case, the input is given in the following format:
For each test case, if it is possible, output the minimum possible value of $$$m$$$ and a sequence of numbers that achieves the answer in the following format:
If it is possible, but you do not output the sequence, output the following:
If there is no possible answer, output the answer in the following format:
465 210 31024 1012 8
2 1 8 3 1 1 2 1 2 12 1 1 1 1 1 1 1 1 1 1 1 1
Example 1
Input
4
65 2
10 3
1024 10
12 8
Partially Correct Output
2 -1
Correct Output
2
1 8
3
1 1 2
1
2
12
1 1 1 1 1 1 1 1 1 1 1 1
Explanation of Example 1: