for t in range(int(input())): N,M=map(int,input().split()) A=list(map(int,input().split())) ANS='Yes' for i in range(N-1): if A[i]+A[i+1]