Sofdor Ali found interest in mathematics very early in his life. And now, he wants to spread this interest to every young mind. But the way some of the Bangladeshi schools asks students to memorize the multiplication table disappoints him. “Multiplication is just repeated addition”, Sofdor says to himself and grieves as many young students do not even know this simple fact.
So he decided to open an online website for students named “Magical Blackboard” where they will be shown simple and yet important mathematical logics and puzzles. One of his lessons includes a puzzle where you will be given a number , and you have to add it times to get the sum. For example, if and , then you need to add 3 times and your answer should be .
Sofdor Ali has already decided about all the possible values for and which he will give to his online students. He asked for your help to write a program, that calculates the correct answer for every pair of and that Sofdor provides to you.
The first line contains an integer (), the number of test cases. The next lines will contain a pair of and ().
For 30 percent of the cases, both and will be less than or equal to .
For every pair of and , produce the correct result that Sofder expects from his students, on a line by itself.
3 2 3 10 10 4 5
6 100 20