By Neilor Tonin, URI Brazil
Paulinho have again in your hands another problem. Now the teacher asked him to make a new program to verify from two big numbers A and B, if B corresponds to the last digit of A.
The input consists of several test cases. The first line of input contains an integer N that indicates the number of test cases. Each test case consists of two numbers A and B greather than zero, with up to 1000 digits each.
For each test case, print a message informing if the second number fit ("encaixa" in portughese) or didn't fit ("nao encaixa") in the first number.
Sample Input | Sample Output |
4 |
encaixa |