Khigoli has been invited to a party. In this party to play the game, the owner of the…
- User
Khigoli has been invited to a party. In this party to play the game, the owner of the house gave each of the guests a square white paper with a positive integer (without any leading zero) written on it. The landlord has claimed that the numbers he gave are unique 1 1 to n are n. Given Khigoli's knowledge of the landlord's character, he guesses that he lied about the numbers. That's why under the eyes of the number k k reads some of the guests and has concluded that the owner of the house lied, do you agree with him?
input The first line contains the number t t is the number of tests.
Notice: t t is a number between 4 and 10.
In the following, each test is as follows: The first line of the input contains two integers in order k , n k,n which indicates the range of numbers and the number of numbers read by Khigoli. In the second line k k is a string of numbers that represents the string that Khegoli saw from the hands of the rest of the guests. 1 ≤ n , k ≤ 1000 1≤n,k≤1000
All the numbers on the papers have a maximum of 5 digits.
output For each test, if you agree with Khigoli, write YES, otherwise, print NO
Example Sample entry 1 3 80 3 9 9 81 50 9 1 2 3 4 5 6 7 8 01 69 3 11 11 31 Plain text Sample output 1 No No YES Plain text Khegoli may have seen the guests' paper with a 180-degree turn, which in this case 6 6 as 9 9 and vice versa is seen and numbers 0 , 1 , 8 0,1,8 remain the same ( 1 1 is written by the landlord in a straight line). According to the above explanation in the first test 9 9 can 6 6 and 81 81 can 18 be 18 but 11 11 and 31 31 only in face 11 11 and 31 31 can be written. write in c++
- Assistant