Integer division 2
Time Limit: 1000 ms Memory Limit: 65536 KiB
This is a very simple problem, just like previous one.
You are given a postive integer n, and you need to divide this integer into m pieces. Then multiply the m pieces together. There are many way to do this. But shadow95 want to know the maximum result you can get.
First line is a postive integer t, means there are T test cases.
Following T lines, each line there are two integer n, m. (0<=n<=10^18, 0 < m < log10(n))
Output the maximum result you can get.
1 123 2
You can divide "123" to "12" and "3".
Then the maximum result is 12*3=36.