


The first line of input contains an integer 'T' which denotes the number of test cases.
The first and the only line of each test case contains two single space-separated integers 'N1' and 'N2'.
For each test case, return the fraction when 'N1' is divided by 'N2'.
You don't need to print anything, it has already been taken care of. Just implement the given function.
1 <= T <= 100
-5000 <= N1 , N2 <= 5000 and N2 != 0
Time limit: 1 sec
The idea is to notice that the fractional part repeats only when we have already seen the same remainder before. So, that means we have to store the end index where this repetition starts in some data structure.
We can use Map / HashMap / Dictionary to store the remainder and its associated index while doing division so that whenever the same remainder comes up, we know there is a repeating fraction part.
The steps are as follows: