T = int(input()) for _ in range(T): 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] < M: ans = 'No' print(ans)