Problem: You are given an array a consisting of n integers.

Let min(l, r) be the minimum value among a_l, a_{l + 1}, …, a_r and max(l, r) be the maximum value among a_l, a_{l + 1}, …, a_r.

Your task is to choose three positive (greater than 0) integers x, y and z such that:

  * x + y + z = n; 
  * max(1, x) = min(x + 1, x + y) = max(x + y + 1, n). 



In other words, you have to split the array a into three consecutive non-empty parts that cover the whole array and the maximum in the first part equals the minimum in the second part and equals the maximum in the third part (or determine it is impossible to find such a partition).

Among all such triples (partitions), you can choose any.

You have to answer t independent test cases.

Input

The first line of the input contains one integer t (1 ≤ t ≤ 2 ⋅ 10^4) — the number of test cases. Then t test cases follow.

The first line of the test case contains one integer n (3 ≤ n ≤ 2 ⋅ 10^5) — the length of a.

The second line of the test case contains n integers a_1, a_2, …, a_n (1 ≤ a_i ≤ 10^9), where a_i is the i-th element of a.

It is guaranteed that the sum of n does not exceed 2 ⋅ 10^5 (∑ n ≤ 2 ⋅ 10^5).

Output

For each test case, print the answer: NO in the only line if there is no such partition of a that satisfies the conditions from the problem statement. Otherwise, print YES in the first line and three integers x, y and z (x + y + z = n) in the second line.

If there are several answers, you can print any.

Example

Input


6
11
1 2 3 3 3 4 4 3 4 2 1
8
2 9 1 7 3 9 4 1
9
2 1 4 2 4 3 3 1 2
7
4 2 1 1 4 1 4
5
1 1 1 1 1
7
4 3 4 3 3 3 4


Output


YES
6 1 4
NO
YES
2 5 2
YES
4 1 2
YES
1 1 3
YES
2 1 4

Solution (in PYTHON3):

Solution:
# Author : nitish420 --------------------------------------------------------------------
import math
import os
import sys
from io import BytesIO, IOBase
# mod=10**9+7
from collections import defaultdict
from bisect import bisect_left

def main():
	for _ in range(int(input())):
		n=int(input())
		arr=list(map(int,input().split()))
		dct=defaultdict(list)
		for i,item in enumerate(arr):
			dct[item].append(i)
		

		col=n.bit_length()
		sparse=[[-1 for _ in range(col)] for _ in range(n)]
		for c in range(col):
			for r in range(n):
				if c==0:
					sparse[r][c]=r
					continue
				if r+(1<<c)<=n:
					z=1<<c
					if arr[sparse[r][c-1]]<arr[sparse[r+(z>>1)][c-1]]:
						sparse[r][c]=sparse[r][c-1]
					else:
						sparse[r][c]=sparse[r+(z>>1)][c-1]
				else:
					break
		postmax=[0]*(n+1)
		dctz=dict()
		for i in range(n):
			postmax[n-i-1]=max(postmax[n-i],arr[n-i-1])

		postmax.pop()
		for i in range(n-2,-1,-1):
			if postmax[i]!=postmax[i+1]:
				dctz[postmax[i+1]]=i
		dctz[postmax[0]]=-1

		# print(postmax)
		def findmin(l,r):
			z=r-l+1
			k=z.bit_length()-1
			ans=arr[sparse[l][k]]
			z-=(1<<k)
			if z:
				ans=min(ans,arr[sparse[l+z][k]])
			return ans

		pre=0
		ans=0
		for i in range(n):
			pre=max(pre,arr[i])
			if pre in dctz:
				y=dct[pre]
				x=bisect_left(y,i+1)
				if x!=len(y):
					z=max(y[x],dctz[pre])
					if z!=n-1 and findmin(i+1,z)==pre and postmax[z+1]==pre:
						ans=[i+1,z-i,n-z-1]
						break
		if ans:
			print("YES")
			print(*ans)
		else:
			print("NO")

# region fastio

BUFSIZE = 8192


class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			self.buffer.truncate(0), self.buffer.seek(0)


class IOWrapper(IOBase):
	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda: self.buffer.read().decode('ascii')
		self.readline = lambda: self.buffer.readline().decode('ascii')


sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
input = lambda: sys.stdin.readline().rstrip('\r\n')


# endregion

if __name__ == '__main__':
	main()