T=int(input())
p=[]
c=0
for i in range(T):
n,k=map(int,input().split())
l=list(map(int,input().split()))
x=sum(l)/n
s=True
for j in l:
if abs(j-x)%k!=0:
print("Draw")
s=False
break
else:
if j>x:
c+=(j-x)/k
if s:
if c%2==0:
print("L")
else:
print("F")