def bt(score,numList):
    n=numList
    lst1=[]
    for k in range(len(scores)):
        lst1.append(btCon(scores[k]))
    return lst1
def btCon(w):
    g,s,b=0,0,0
    mid=len(w)//2
    if(mid<5):
        return "0 0 0"
    while(w[mid]==w[mid-1]):
        mid=mid-1
        if(mid==4):
            return "0 0 0"
    medalists=w[:mid]
    maxScore=medalists[0]
    g=1
    while(g<len(medalists)):
        if(medalists[g]<maxScore):
            break
        g+=1
    res=len(medalists)-g
    if(res//2<g):
        return "0 0 0"
    maxScore=medalists[g+1]
    s=1
    while(s+g<len(medalists)):
        if(s>g):                
            if(medalists[s+g]<maxScore):
                break
        s+=1
    res=len(medalists)-g-s
    if(res<g):
        return "0 0 0"
    b=1
    while(b+s+g<len(medalists)):
        b+=1
    if(g<s and g<b):
        return str(g)+" "+str(s)+" "+str(b)
    else:
        return "0 0 0"
    
test=eval(input())
scores=[]
numlst=[]
for i in range(test):
    num=eval(input())
    score=input()
    scores.append(score.split(" "))
    numlst.append(num)
lst=(bt(scores,numlst))
for j in lst:
    print(j)
