You are given a permutation $p_1, p_2, \dots, p_n$. Recall that sequence of $n$ integers is called a permutation if it contains all integers from $1$ to $n$ exactly once.

Find three indices $i$, $j$ and $k$ such that:   $1 \le i < j < k \le n$;  $p_i < p_j$ and $p_j > p_k$.  Or say that there are no such indices.


-----Input-----

The first line contains a single integer $T$ ($1 \le T \le 200$) — the number of test cases.

Next $2T$ lines contain test cases — two lines per test case. The first line of each test case contains the single integer $n$ ($3 \le n \le 1000$) — the length of the permutation $p$.

The second line contains $n$ integers $p_1, p_2, \dots, p_n$ ($1 \le p_i \le n$; $p_i \neq p_j$ if $i \neq j$) — the permutation $p$.


-----Output-----

For each test case:   if there are such indices $i$, $j$ and $k$, print YES (case insensitive) and the indices themselves;  if there are no such indices, print NO (case insensitive). 

If there are multiple valid triples of indices, print any of them.


-----Example-----
Input
3
4
2 1 4 3
6
4 6 1 2 5 3
5
5 3 1 2 4

Output
YES
2 3 4
YES
3 5 6
NO

Source: codeforces | Difficulty: EASY
Tags: Data structures

Complete search


Solutions:
for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	a = []
	f = 0
	for i in range(len(p) - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			a.append([p.index(p[i]) + 1, p.index(p[i + 1]) + 1, p.index(p[i + 2]) + 1])
			f = 1
			break
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(' '.join(map(str, a[0])))


for _ in range(int(input())):
	n = int(input())
	case = True
	a = [*map(int, input().split())]
	for i in range(0, n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			case = False
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	if case:
		print('NO')


t = int(input())
while t:
	n = int(input())
	l = list(map(int, input().split()))
	flag = 0
	for i in range(n - 2):
		j = i + 1
		k = j + 1
		if l[j] > l[i] and l[j] > l[k]:
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')
	t = t - 1


for _ in range(int(input())):
	total = int(input())
	array = list(map(int, input().split()))
	first = array[0]
	result = False
	for i in range(1, len(array) - 1):
		if array[i] > array[i - 1] and array[i] > array[i + 1]:
			result = True
			print('YES')
			print(i, i + 1, i + 2)
			break
	if not result:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	ls = list(map(int, input().split()))
	mx = -1
	mn = 10000000000
	a1 = -1
	a2 = -1
	a3 = -1
	f = False
	for i in range(n):
		if ls[i] < mx and a1 != a2 != -1 and (a2 > a1):
			a3 = i + 1
			print('YES')
			print(a1, a2, a3)
			f = True
			break
		if ls[i] < mn:
			mn = ls[i]
			mx = -1
			a1 = i + 1
		if ls[i] > mn:
			mx = max(mx, ls[i])
			a2 = i + 1
	if not f:
		print('NO')


INT_MAX = 10 ** 11 + 7
MOD = 10 ** 9 + 7

def INPUT():
	return list((int(i) for i in input().split()))

def LIST_1D_ARRAY(n):
	return [0 for _ in range(n)]

def LIST_2D_ARRAY(m, n):
	return [[0 for _ in range(n)] for _ in range(m)]
GETA = 12
for _ in range(int(input())):
	n = int(input())
	A = INPUT()
	ind = -1
	for i in range(1, n - 1):
		if A[i] > A[i - 1] and A[i] > A[i + 1]:
			ind = i
			break
	if ind == -1:
		print('NO')
	else:
		print('YES')
		print(ind, ind + 1, ind + 2)


tests = int(input())
for _ in range(tests):
	n = int(input())
	a = list(map(int, input().split()))

	def search():
		for x in range(n - 2):
			(y, z) = (x + 1, x + 2)
			if a[y] > max(a[x], a[z]):
				return (x, y, z)
	res = search()
	if not res:
		print('NO')
	else:
		print('YES')
		(x, y, z) = res
		print(x + 1, y + 1, z + 1)


for i in range(int(input())):
	n = int(input())
	lst = [int(x) for x in input().split()]
	found = False
	for i in range(0, n - 2):
		if lst[i + 1] > lst[i] and lst[i + 1] > lst[i + 2]:
			found = True
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	if found == False:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	l = [int(i) for i in input().split()]
	if len(set(l)) == 1 or len(set(l)) == 2:
		print('NO')
	elif n == 3:
		if l[0] < l[1] and l[1] > l[2]:
			print('YES')
			print(1, 2, 3)
		else:
			print('NO')
	else:
		for i in range(n - 2):
			if l[i] < l[i + 1] and l[i + 1] > l[i + 2]:
				print('YES')
				print(i + 1, i + 2, i + 3)
				break
		else:
			print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	i = 0
	k = 0
	while i + 3 <= len(l):
		if l[i + 1] > l[i] and l[i + 1] > l[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			k += 1
			break
		i += 1
	if k == 0:
		print('NO')


import sys, math, cmath, time
start_time = time.time()

def solve():
	n = inp()
	a = inlt()
	q = -1
	w = -1
	for i in range(1, len(a) - 1):
		if a[i - 1] < a[i]:
			q = i
			break
	for i in range(q - 1, len(a) - 1):
		if a[i + 1] < a[i]:
			w = i + 1
			break
	qw = a.index(min(a[w:])) + 1
	if q != -1 and w != -1:
		print('YES')
		print(q, w, qw)
	else:
		print('NO')

def main():
	global tt
	if not ONLINE_JUDGE:
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	t = 1
	t = inp()
	for tt in range(t):
		solve()
	if not ONLINE_JUDGE:
		print('Time Elapsed :', time.time() - start_time, 'seconds')
		sys.stdout.close()

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	return input().strip()

def invr():
	return map(int, input().split())

def counter(a, qw):
	q = [0] * qw
	for i in range(len(a)):
		q[a[i] - 1] = q[a[i] - 1] + 1
	return q

def counter_elements(a):
	q = dict()
	for i in range(len(a)):
		if a[i] not in q:
			q[a[i]] = 0
		q[a[i]] = q[a[i]] + 1
	return q

def string_counter(a):
	q = [0] * 26
	for i in range(len(a)):
		q[ord(a[i]) - 97] = (q[ord(a[i]) - 97], 1)
	return q

def factors(n):
	q = []
	for i in range(1, int(n ** 0.5) + 1):
		if n % i == 0:
			q.append(i)
			q.append(n // i)
	return list(sorted(list(set(q))))

def prime_factors(n):
	q = []
	while n % 2 == 0:
		q.append(2)
		n = n // 2
	for i in range(3, int(n ** 0.5) + 1, 2):
		while n % i == 0:
			q.append(i)
			n = n // i
	if n > 2:
		q.append(n)
	return list(sorted(q))

def transpose(a):
	(n, m) = (len(a), len(a[0]))
	b = [[0] * n for i in range(m)]
	for i in range(m):
		for j in range(n):
			b[i][j] = a[j][i]
	return b
ONLINE_JUDGE = __debug__
if ONLINE_JUDGE:
	input = sys.stdin.readline
main()


input_length = int(input())
while input_length != 0:
	n = int(input())
	num_string = str(input())
	input_length -= 1
	num_array = num_string.split()
	num_array = [int(x) for x in num_string.split()]
	minnow = {0: (num_array[0], 0)}
	maxnow = {n - 1: (num_array[n - 1], n - 1)}
	for i in range(1, n):
		if num_array[i] <= minnow[i - 1][0]:
			minnow[i] = (num_array[i], i)
		else:
			minnow[i] = minnow[i - 1]
	for i in range(n - 2, -1, -1):
		if num_array[i] <= maxnow[i + 1][0]:
			maxnow[i] = (num_array[i], i)
		else:
			maxnow[i] = maxnow[i + 1]
	found = False
	for i in range(0, n):
		if minnow[i][0] < num_array[i] and num_array[i] > maxnow[i][0]:
			print('yes')
			print(minnow[i][1] + 1, i + 1, maxnow[i][1] + 1)
			found = True
			break
	if not found:
		print('NO')


__MULTITEST = True

def solve():
	n = int(input())
	a = list(map(int, input().split()))
	minL = [x for x in range(n)]
	minR = [x for x in range(n)]
	for i in range(1, n):
		if a[minL[i]] > a[minL[i - 1]]:
			minL[i] = minL[i - 1]
	for i in range(n - 2, -1, -1):
		if a[minR[i]] > a[minR[i + 1]]:
			minR[i] = minR[i + 1]
	for i in range(1, n - 1):
		if minL[i] != i and minR[i] != i:
			print('YES')
			print(minL[i] + 1, i + 1, minR[i] + 1)
			return
	print('NO')
t = int(input()) if __MULTITEST else 1
for tt in range(t):
	solve()


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	c = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			c = 1
			break
	if c == 0:
		print('NO')


import sys
input = lambda : sys.stdin.readline().strip()
t = int(input())
while t:
	t -= 1
	n = int(input())
	p = list(map(int, input().split()))
	ok = False
	pre = [[float('inf'), -1] for _ in range(n)]
	suf = [[float('inf'), -1] for _ in range(n)]
	pre[0][0] = p[0]
	pre[0][1] = 0
	for i in range(1, n):
		if p[i] < pre[i - 1][0]:
			pre[i] = [p[i], i]
		else:
			pre[i] = pre[i - 1]
	suf[n - 1] = [p[n - 1], n - 1]
	for i in range(n - 2, -1, -1):
		if p[i] < suf[i + 1][0]:
			suf[i] = [p[i], i]
		else:
			suf[i] = suf[i + 1]
	ans = []
	for i in range(1, n - 1):
		if p[i] > pre[i - 1][0] and p[i] > suf[i + 1][0]:
			ok = True
			ans = [pre[i - 1][1], i, suf[i + 1][1]]
			break
	if ok:
		print('YES')
		print(ans[0] + 1, ans[1] + 1, ans[2] + 1)
	else:
		print('NO')


t = int(input())
for j in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	flag = 0
	for i in range(n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			flag = 1
			break
	if flag == 0:
		print('NO')


n = int(input())

def perest(numbers, mx):
	curmin = mx
	pret = 0
	(ii, j, k) = (-1, -1, -1)
	for (i, num) in enumerate(numbers):
		if pret > num:
			k = i + 1
			break
		if (num > curmin) & (num > pret):
			pret = num
			j = i + 1
		elif num < curmin:
			curmin = num
			pret = 0
			ii = i + 1
	return (ii, j, k)
for _ in range(n):
	count = int(input())
	number_list = list(map(int, input().split()))
	ans = perest(number_list, count)
	if (ans[0] == -1) | (ans[1] == -1) | (ans[2] == -1):
		print('NO')
	else:
		print('YES')
		print(*ans)


def solve(N, A):
	(i, j, k) = (None, None, None)
	for (idx, x) in enumerate(A):
		if i is None:
			if idx + 1 < N and x < A[idx + 1]:
				i = idx
		elif j is None:
			if x > A[i]:
				j = idx
		elif k is None:
			if x < A[j]:
				return (True, (i, j, idx))
			elif x > A[j]:
				j = idx
	return (False, (None, None, None))

def main():
	T = int(input())
	for _ in range(T):
		N = int(input())
		A = list(map(int, input().split()))
		(ans, indicies) = solve(N, A)
		if ans:
			print('YES')
			print(' '.join(map(lambda x: str(x + 1), indicies)))
		else:
			print('NO')
main()


nb = int(input())
for _ in range(nb):
	nb_element = int(input())
	input1 = input()
	lst = input1.split(' ')
	l = len(lst)
	switch = False
	i = 0
	j = 0
	k = 0
	for a in range(1, l):
		if k == 0:
			n = int(lst[a])
			n1 = int(lst[a - 1])
			if switch:
				if n1 > n and k == 0:
					k = a
				if n1 < n and k == 0:
					j = a
			elif n1 < n:
				i = a - 1
				j = a
				switch = True
	if k != 0 and switch:
		print('YES')
		m = str(i + 1) + ' ' + str(j + 1) + ' ' + str(k + 1)
		print(m)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = [*map(int, input().split())]
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	pos = [0 for i in range(n + 1)]
	for i in range(n):
		pos[arr[i]] = i
	l = 10 ** 10
	r = -10 ** 10
	for i in range(1, 3):
		l = min(l, pos[i])
		r = max(r, pos[i])
	f = 0
	for i in range(3, n + 1):
		if l < pos[i] and r > pos[i]:
			print('YES')
			print(l + 1, pos[i] + 1, r + 1)
			f = 1
			break
		l = min(l, pos[i])
		r = max(r, pos[i])
	if f == 0:
		print('NO')


import sys
import math
import collections
import heapq

def set_debug(debug_mode=False):
	if debug_mode:
		fin = open('input.txt', 'r')
		sys.stdin = fin

def int_input():
	return list(map(int, input().split()))
t = int(input())
for ti in range(1, t + 1):
	n = int(input())
	A = int_input()
	cur = n
	l = 0
	r = n - 1
	find = False
	while cur >= 1:
		pos = A.index(cur)
		if l < pos < r:
			find = True
			print('YES')
			print(l + 1, pos + 1, r + 1)
			break
		elif pos == l:
			l += 1
		elif pos == r:
			r -= 1
		cur -= 1
	if not find:
		print('NO')


t = int(input())
while t > 0:
	t -= 1
	n = int(input())
	p = input().split()
	i = 0
	while i < n:
		p[i] = int(p[i])
		i += 1
	i = 0
	flag = 0
	while i < n:
		if p[i] == n:
			if i == 0 or i == n - 1:
				break
			else:
				print('YES')
				print(i, i + 1, i + 2)
				flag = 1
				break
		i += 1
	if flag == 1:
		continue
	stack = []
	stack.append(p[0])
	i = 1
	while i < n:
		if p[i] > stack[-1]:
			stack.append(p[i])
		elif len(stack) > 1 and p[i] < stack[-1]:
			stack.append(p[i])
			break
		elif len(stack) == 1 and p[i] < stack[-1]:
			stack.pop()
			stack.append(p[i])
		i += 1
	if len(stack) < 3:
		print('NO')
		continue
	s = stack[0]
	l = stack[-1]
	m = stack[-2]
	if stack[-1] > stack[-2]:
		print('NO')
		continue
	i = 0
	while i < n:
		if p[i] == s:
			sf = i + 1
		if p[i] == l:
			lf = i + 1
		if p[i] == m:
			mf = i + 1
		i += 1
	print('YES')
	print(sf, mf, lf)


import sys
for _ in range(int(sys.stdin.readline().rstrip())):
	n = int(sys.stdin.readline().rstrip())
	p = list(map(int, sys.stdin.readline().rstrip().split()))
	result = False
	re = ''
	for j in range(n):
		pi = -1
		for i in range(0, j):
			if p[i] < p[j]:
				pi = i
				break
		pz = -1
		for z in range(j + 1, n):
			if p[z] < p[j]:
				pz = z
				break
		if pi != -1 and pz != -1:
			result = True
			re = str(pi + 1) + ' ' + str(j + 1) + ' ' + str(pz + 1)
			break
	if result:
		print('YES')
		print(re)
	else:
		print('NO')


t = int(input())
for tt in range(t):
	n = int(input())
	x = input()
	a = x.split()
	c = 0
	for i in range(1, len(a) - 1):
		if int(a[i]) > int(a[i - 1]) and int(a[i]) > int(a[i + 1]):
			print('YES')
			print(i, i + 1, i + 2)
			c = 1
			break
	if c == 0:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = input().split()
	a = list(map(int, a))
	b = [0 for i in range(n)]
	k = a[0]
	for i in range(1, n):
		if k > a[i]:
			k = a[i]
			b[i] = i
		else:
			b[i] = b[i - 1]
	c = [0 for i in range(n)]
	c[n - 1] = n - 1
	k = a[n - 1]
	for i in range(n - 2, -1, -1):
		if k > a[i]:
			k = a[i]
			c[i] = i
		else:
			c[i] = c[i + 1]
	k = 0
	for i in range(n):
		if (i > b[i]) & (i < c[i]):
			k = 1
			print('YES')
			print(b[i] + 1, i + 1, c[i] + 1)
			break
	if k == 0:
		print('NO')


n = int(input())
while n > 0:
	n -= 1
	si = int(input())
	a = list(map(int, input().split()))
	res = []
	flag = False
	for i in range(1, si - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			res.append(i)
			res.append(i + 1)
			res.append(i + 2)
			flag = True
			break
	if flag:
		print('YES')
		for i in res:
			print(i, end=' ')
		print()
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	permutation_array = list(map(int, input().split()))
	for (j, p_j) in enumerate(permutation_array[1:-1], start=1):
		max_i = min(permutation_array[:j])
		max_k = min(permutation_array[j + 1:])
		if max_i < p_j > max_k:
			print('YES')
			print(permutation_array.index(max_i) + 1, j + 1, permutation_array.index(max_k) + 1)
			break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	temp = 0
	my_lst = list(map(int, input().split()))
	for i in range(1, n - 1):
		if my_lst[i] > my_lst[i - 1] and my_lst[i] > my_lst[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			temp = 1
			break
	if temp == 0:
		print('NO')


for T in range(int(input())):
	n = int(input())
	f = False
	p = list(map(int, input().split(' ')))
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			f = True
			break
	if not f:
		print('NO')


from sys import stdin, stdout
int_in = lambda : int(stdin.readline())
arr_in = lambda : [int(x) for x in stdin.readline().split()]
mat_in = lambda rows: [arr_in() for _ in range(rows)]
str_in = lambda : stdin.readline().strip()
out = lambda o: stdout.write('{}\n'.format(o))
arr_out = lambda o: out(' '.join(map(str, o)))
bool_out = lambda o: out('YES' if o else 'NO')
tests = lambda : range(1, int_in() + 1)
case_out = lambda i, o: out('Case #{}: {}'.format(i, o))

def solve(n, p):
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			return [i, i + 1, i + 2]
	return None
for _ in tests():
	n = int_in()
	p = arr_in()
	result = solve(n, p)
	bool_out(result)
	if result:
		arr_out(result)


t = int(input())
for _ in range(t):
	n = int(input())
	p = [int(i) for i in input().split()]
	one_i = -1
	two_i = -1
	for i in range(len(p)):
		if p[i] == 1:
			one_i = i
		elif p[i] == 2:
			two_i = i
		if one_i != -1 and two_i != -1:
			break
	if abs(one_i - two_i) != 1:
		print('YES')
		print(min(one_i, two_i) + 1, min(one_i, two_i) + 2, max(one_i, two_i) + 1)
	else:
		flag = True
		for i in range(min(one_i, two_i), 0, -1):
			if p[i] > p[i - 1]:
				print('YES')
				print(*sorted([min(one_i, two_i) + 1, i + 1, i]))
				flag = False
				break
		if flag:
			for i in range(max(one_i, two_i), n - 1):
				if p[i] > p[i + 1]:
					print('YES')
					print(*sorted([max(one_i, two_i) + 1, i + 1, i + 2]))
					break
			else:
				print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	p = 0
	mi = [l[0], 0]
	for i in range(1, n):
		if l[i] < mi[0]:
			mi = [l[i], i]
		else:
			p = i
			break
	q = n - 1
	mo = [l[-1], n - 1]
	for i in range(n - 2, -1, -1):
		if l[i] < mo[0]:
			mo = [l[i], i]
		else:
			q = i
			break
	if l[p] > l[q]:
		b = p + 1
	else:
		b = q + 1
	a = mi[-1] + 1
	c = mo[-1] + 1
	if a != b and b != c and (c != a):
		print('YES')
		print(mi[-1] + 1, b, mo[-1] + 1)
	else:
		print('NO')


def solve(n, a):
	for i in range(n):
		if i == 0 or i == n - 1:
			continue
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES\n', i, i + 1, i + 2)
			return
	print('NO')
	return

def main():
	inp = lambda : [int(x) for x in input().split()]
	tc = int(input())
	for _ in range(tc):
		n = int(input())
		a = inp()
		solve(n, a)
main()


t = int(input(''))
for i in range(t):
	n = int(input(''))
	a = list(map(int, input('').split()))
	count = 0
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			count += 1
			print('YES')
			print(f'{i + 1} {i + 2} {i + 3}')
			break
	if count == 0:
		print('NO')


from collections import Counter
from math import ceil, gcd, log, log2
for _ in range(int(input())):
	n = int(input())
	arr = [int(x) for x in input().split()]
	if len(set(arr)) != n:
		print('NO')
	else:
		k = False
		for i in range(n - 2):
			if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
				k = True
				a = i + 1
				b = a + 1
				c = b + 1
				break
		if k:
			print('YES')
			print(a, b, c)
		else:
			print('NO')


for _ in range(int(input())):
	n = int(input())
	i = j = k = -1
	l = list(map(int, input().split()))
	t = 0
	while t != n - 1 and k == -1:
		if i == -1:
			if l[t] < l[t + 1]:
				i = t
				j = t + 1
		elif k == -1:
			if l[t + 1] < l[t]:
				k = t + 1
				j = t
		t += 1
	if k != -1:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


def solve():
	n = int(input())
	lst = list(map(int, input().split()))
	minel = n + 1
	minpos = -1
	maxel = 0
	maxpos = -1
	p = -1
	for i in lst:
		p += 1
		if maxel:
			if i < maxel:
				print('YES')
				print(minpos + 1, maxpos + 1, p + 1)
				return 0
			else:
				maxel = i
				maxpos = p
		elif minel < i:
			maxel = i
			maxpos = p
		else:
			minel = i
			minpos = p
	print('NO')
for i in range(int(input())):
	solve()


def solve():
	n = int(input())
	a = list(map(int, input().split()))
	minn = [0 for i in range(n)]
	minn1 = [0 for i in range(n)]
	p = [0 for i in range(n + 1)]
	for i in range(n):
		p[a[i]] = i
	minn[0] = a[0]
	for i in range(1, n):
		minn[i] = min(minn[i - 1], a[i])
	minn1[-1] = a[-1]
	for i in range(n - 2, -1, -1):
		minn1[i] = min(minn1[i + 1], a[i])
	for i in range(1, n - 1):
		if minn[i - 1] < a[i] and minn1[i + 1] < a[i]:
			print('YES')
			print(p[minn[i - 1]] + 1, i + 1, p[minn1[i + 1]] + 1)
			return
	print('NO')
t = int(input())
for i in range(t):
	solve()


import sys
input = sys.stdin.readline
t = int(input())

def func():
	for i in range(1, n - 1):
		if nList[i] > nList[i - 1] and nList[i] > nList[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	return print('NO')
for _ in range(t):
	n = int(input())
	nList = list(map(int, input().split()))
	func()


t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	flag = 0
	for j in range(1, n - 1):
		if a[j - 1] < a[j] > a[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


def solve():
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(n, 0, -1):
		jj = -1
		for j in range(n):
			if a[j] == i:
				jj = j
				break
		ii = -1
		for j in range(jj):
			if a[j] < i:
				ii = j
				break
		kk = -1
		for j in range(jj + 1, n):
			if a[j] < i:
				kk = j
				break
		if min(ii, kk) != -1:
			print('YES')
			print(ii + 1, jj + 1, kk + 1)
			return
	print('NO')
for _ in range(int(input())):
	solve()


def function(n, arr):
	for j in range(1, n - 1):
		if arr[j] > arr[j - 1] and arr[j] > arr[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			return
	print('NO')
	return
t = int(input())
while t:
	n = int(input())
	arr = list(map(int, input().rstrip().split()))
	function(n, arr)
	t -= 1


for _ in range(int(input())):
	N = int(input())
	A = list(map(int, input().split()))
	temp = 0
	for i in range(1, N - 1):
		if A[i] > A[i - 1] and A[i] > A[i + 1]:
			temp = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if temp == 0:
		print('NO')


for t in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	ans = 'NO'
	for i in range(1, n - 1):
		if p[i - 1] < p[i] > p[i + 1]:
			ans = 'YES'
			a = (i, i + 1, i + 2)
	if ans == 'NO':
		print(ans)
	else:
		print(ans)
		print(*a)


def solve():
	n = int(input())
	p = list(map(int, input().split()))
	k = False
	for i in range(1, n):
		if p[i] > p[i - 1]:
			k = True
		elif k:
			print('YES')
			print(i - 1, i, i + 1)
			return
	print('NO')
for _ in range(int(input())):
	solve()


for i in range(int(input())):
	n = int(input())
	a = [int(num) for num in input().split()]
	(j, c) = (0, 0)
	while j < n - 2:
		if a[j] < a[j + 1] > a[j + 2]:
			print('YES')
			c = 1
			print(j + 1, j + 2, j + 3)
			break
		else:
			j = j + 1
	if c == 0:
		print('NO')


test_case = int(input())
for _ in range(test_case):
	n = int(input())
	arr = list(map(int, input().split()))
	x = []
	for i in range(1, len(arr)):
		for j in range(i):
			if arr[j] < arr[i]:
				x.append(j)
				break
		x.append(i)
		for j in range(i + 1, len(arr)):
			if arr[i] > arr[j]:
				x.append(j)
				break
		if len(x) == 3:
			break
		else:
			x = []
	if len(x):
		print('YES')
		print(x[0] + 1, x[1] + 1, x[2] + 1)
	else:
		print('NO')


def solve():
	N = int(input())
	line = input()
	A = [int(x) for x in line.split()]
	for i in range(1, N - 1):
		if A[i - 1] < A[i] and A[i] > A[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
K = int(input())
for k in range(K):
	solve()


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	d = [0] * n
	for i in range(n):
		d[p[i] - 1] = i + 1
	mi = n + 1
	ma = 0
	for x in d:
		if mi < x < ma:
			print('YES')
			print(mi, x, ma)
			break
		if mi > x:
			mi = x
		if ma < x:
			ma = x
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	a1 = []
	a2 = []
	s = 0
	mini = n + 1
	for j in range(n - 2):
		mini = min(mini, a[j])
		a1.append(mini)
	mini = n + 1
	for j in range(1, n - 1):
		mini = min(mini, a[-j])
		a2.append(mini)
	a3 = []
	for j in range(1, n - 1):
		a3.append(a2[-j])
	for j in range(1, n - 1):
		if a[j] > a1[j - 1] and a[j] > a3[j - 1]:
			s += 1
			print('YES')
			print(a.index(a1[j - 1]) + 1, j + 1, a.index(a3[j - 1]) + 1)
			break
	if s == 0:
		print('NO')


for tests in range(int(input())):
	n = int(input())
	p = [int(x) for x in input().split()]
	found = False
	for i in range(n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			found = True
			break
	if not found:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	diff = []
	for i in range(1, n):
		diff.append(l[i] - l[i - 1])
	for i in range(0, n - 1):
		if diff[i] > 0:
			break
	if i == n - 2:
		print('NO')
		continue
	ans = False
	for j in range(i + 1, n - 1):
		if diff[j] < 0:
			print('YES')
			print(i + 1, j + 1, j + 2)
			ans = True
			break
	if not ans:
		print('NO')


R = lambda : map(int, input().split())
(t,) = R()
for _ in range(t):
	n = int(input())
	a = list(R())
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


import sys

def solve():
	t = int(input())
	for tests in range(0, t):
		n = int(input())
		a = list(map(int, input().split()))
		ok = False
		pos = -1
		for idx in range(1, n - 1):
			if a[idx - 1] < a[idx] and a[idx] > a[idx + 1]:
				pos = idx
		if pos == -1:
			print('NO')
		else:
			print('YES')
			print(pos, pos + 1, pos + 2)

def main():
	solve()
main()


t = int(input())
for i in range(0, t):
	n = int(input())
	a = input().split()
	c = []
	for j in a:
		c.append(int(j))
	a = c
	if a[0] == min(a):
		bl = True
		for k in range(0, len(a) - 1):
			if a[k] <= a[k + 1]:
				continue
			else:
				bl = False
				break
		if not bl:
			print('YES')
			print(1, k + 1, k + 2)
		else:
			print('NO')
	elif a[len(a) - 1] == min(a):
		bl = True
		for k in range(len(a) - 1, 0, -1):
			if a[k - 1] >= a[k]:
				continue
			else:
				bl = False
				break
		if not bl:
			print('YES')
			print(k, k + 1, len(a))
		else:
			print('NO')
	else:
		m = a.index(min(a))
		b = a[:m + 1]
		d = a[m:]
		bl1 = True
		for k in range(len(b) - 1, 0, -1):
			if b[k - 1] >= b[k]:
				continue
			else:
				bl1 = False
				break
		if not bl1:
			print('YES')
			print(k, k + 1, len(b))
		bl2 = True
		for k in range(0, len(d) - 1):
			if d[k] <= d[k + 1]:
				continue
			else:
				bl2 = False
				break
		if bl2 == False and bl1 == True:
			print('YES')
			print(1 + m, k + 1 + m, k + 2 + m)
		if bl1 and bl2:
			print('NO')


for t in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	flag = False
	for i in range(n - 2):
		if l[i] < l[i + 1] > l[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			flag = True
			break
	if not flag:
		print('NO')


t = int(input())
for _t in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	(i, j, k) = (0, 0, 0)
	b = False
	for index in range(1, n - 1):
		if l[index] > l[index + 1] and l[index] > l[index - 1]:
			i = index
			j = index + 1
			k = index + 2
			b = True
	if b:
		print('YES')
		print(i, j, k)
	else:
		print('NO')


def solve():
	n = int(input())
	arr = [int(v) for v in input().split()]
	dq = []
	for i in range(n):
		if not dq:
			dq.append(i)
		else:
			while dq and arr[dq[-1]] > arr[i]:
				if len(dq) > 1 and arr[dq[0]] < arr[dq[-1]]:
					print('YES')
					print(dq[0] + 1, dq[-1] + 1, i + 1)
					return
				dq.pop(-1)
			dq.append(i)
	print('NO')
t = int(input())
for _ in range(t):
	solve()


t = int(input())
for i in range(t):
	n = int(input())
	a = [int(v) for v in input().split()]
	f = 0
	j = 0
	p = -1
	q = -1
	while j < n - 1:
		if a[j] < a[j + 1]:
			p = j
		elif p >= 0:
			q = j + 1
			break
		j = j + 1
	if q == -1:
		print('NO')
	else:
		print('YES')
		print(p + 1, p + 2, q + 1)


import sys

def input():
	return sys.stdin.readline().strip()

def list2d(a, b, c):
	return [[c] * b for i in range(a)]

def list3d(a, b, c, d):
	return [[[d] * c for j in range(b)] for i in range(a)]

def list4d(a, b, c, d, e):
	return [[[[e] * d for j in range(c)] for j in range(b)] for i in range(a)]

def ceil(x, y=1):
	return int(-(-x // y))

def INT():
	return int(input())

def MAP():
	return map(int, input().split())

def LIST(N=None):
	return list(MAP()) if N is None else [INT() for i in range(N)]

def Yes():
	print('Yes')

def No():
	print('No')

def YES():
	print('YES')

def NO():
	print('NO')
INF = 10 ** 19
MOD = 10 ** 9 + 7
for _ in range(INT()):
	N = INT()
	A = LIST()
	idx1 = idx2 = idx3 = -1
	for i in range(N - 1):
		if A[i] < A[i + 1]:
			idx1 = i
		if idx1 != -1 and A[i] > A[i + 1]:
			idx2 = i
			idx3 = i + 1
			break
	if idx3 != -1:
		YES()
		print(idx1 + 1, idx2 + 1, idx3 + 1)
	else:
		NO()


import math
from collections import defaultdict, deque
from sys import stdin
from bisect import bisect_left, bisect_right

def mp():
	return map(int, stdin.readline().split())

def ml():
	return list(map(int, stdin.readline().split()))
for _ in range(int(input())):
	n = int(input())
	(x, y, z) = (-1, -1, -1)
	a = ml()
	i = 0
	flag = False
	ans = False
	while i < n - 1:
		if a[i] < a[i + 1]:
			flag = True
			i += 1
			continue
		if flag and a[i] > a[i + 1]:
			ans = True
			x = i - 1
			y = i
			z = i + 1
			break
		i += 1
	if ans:
		print('YES')
		print(x + 1, y + 1, z + 1)
	else:
		print('NO')


def find(s, n, i):
	if n <= 2:
		return ['NO']
	y = max(s)
	index = s.index(y)
	if 0 < index < n - 1:
		return ['YES', index + i, index + 1 + i, index + 2 + i]
	if index == 0:
		return find(s[1:], n - 1, i + 1)
	return find(s[:n - 1], n - 1, i)
ss = []
for iii in range(int(input())):
	n = int(input())
	s = list(map(int, input().split()))
	y = find(s, n, 0)
	if len(y) == 1:
		ss.append(y)
	else:
		ss.append([y[0]])
		ss.append(y[1:])
for i in ss:
	for j in i:
		print(j, end=' ')
	print()


import sys
input = lambda : sys.stdin.readline()
exec("try:sys.stdin=open('in.txt','r');sys.stdout=open('out.txt','w')\nexcept:pass")
for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	ok = False
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			ok = True
			break
	if not ok:
		print('NO')


from sys import stdin
for _ in range(int(stdin.readline())):
	n = int(stdin.readline())
	a = list(map(int, stdin.readline().split()))
	res = False
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			res = True
			break
	if res:
		continue
	print('NO')


def solution(trans: list) -> list:
	stack = [0]
	for i in range(1, len(trans)):
		if len(stack) == 1:
			if trans[stack[0]] >= trans[i]:
				stack.pop()
		elif len(stack) == 2:
			if trans[stack[1]] <= trans[i]:
				stack.pop()
		else:
			return list(map(lambda x: x + 1, stack))
		stack.append(i)
	if len(stack) == 3:
		return list(map(lambda x: x + 1, stack))
	else:
		return []

def main():
	for _ in range(int(input())):
		_ = input()
		ans = solution(list(map(int, input().split(' '))))
		if ans:
			print('YES')
			print(ans[0], ans[1], ans[2])
		else:
			print('NO')
main()


def findpeak(arr):
	low = arr[0]
	low_index = 1
	highest = 0
	for i in range(1, n):
		if arr[i] < low:
			if highest == 0:
				low = arr[i]
				low_index = i + 1
				continue
			else:
				print('YES')
				print(low_index, high_index, i + 1)
				return
		if arr[i] > highest:
			highest = arr[i]
			high_index = i + 1
		else:
			print('YES')
			print(low_index, high_index, i + 1)
			return
	else:
		print('NO')
t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().strip().split()))
	findpeak(arr)


import io
import os

def solve(N, P):
	for j in range(N):
		hasLess = None
		hasGreater = None
		for i in range(j):
			if P[i] < P[j]:
				hasLess = i
				break
		for k in range(j + 1, N):
			if P[j] > P[k]:
				hasGreater = k
				break
		if hasLess is not None and hasGreater is not None:
			i = hasLess
			k = hasGreater
			assert i < j < k
			return 'YES\n' + str(i + 1) + ' ' + str(j + 1) + ' ' + str(k + 1)
	return 'NO'
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
T = int(input())
for t in range(T):
	(N,) = [int(x) for x in input().split()]
	P = [int(x) for x in input().split()]
	ans = solve(N, P)
	print(ans)


test = int(input())
for _ in range(test):
	n = int(input())
	arr = list(map(int, input().split()))
	(i, j, k) = (-1, -1, -1)
	(pi, pj, pk) = (1001, 0, 0)
	ans = 'NO'
	flag = 0
	for (index, a) in enumerate(arr):
		if a < pi and pj == 0:
			pi = a
			i = index + 1
		elif pj < a and a > pi and (pk == 0):
			pj = a
			j = index + 1
		elif pi != 0 and pj != 0 and (a < pj):
			pk = a
			k = index + 1
			flag = 1
			break
	if flag == 1:
		ans = 'YES'
		print(ans)
		print(i, ' ', j, ' ', k)
	else:
		print(ans)


t = int(input())
for a in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	(i, j, k) = (0, 0, 0)
	for b in range(0, n - 2):
		if p[b] < p[b + 1] and p[b + 1] > p[b + 2]:
			(i, j, k) = (b + 1, b + 2, b + 3)
	if i == j:
		print('NO')
	else:
		print('YES')
		print(i, j, k)


for _ in range(int(input())):
	am = int(input())
	arr = list(map(int, input().split()))
	for i in range(1, am - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	fl = 0
	a = [int(i) for i in input().split()]
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			fl = 1
			break
	if fl == 0:
		print('NO')


from math import *
from collections import *
from bisect import *
import sys
input = sys.stdin.readline
t = int(input())
cc = 0
while t:
	t -= 1
	n = int(input())
	a = list(map(int, input().split()))
	ff = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			ff = 1
			break
	if ff ^ 1:
		print('NO')


t = int(input())
while t != 0:
	n = int(input())
	list1 = list(map(int, input().split()))
	maxi1 = [-(1000000000.0 + 7)] * n
	maxi2 = [-(1000000000.0 + 7)] * n
	maxi1[0] = list1[0]
	maxi2[-1] = list1[-1]
	for i in range(1, n):
		maxi1[i] = min(maxi1[i - 1], list1[i])
	for i in range(n - 2, -1, -1):
		maxi2[i] = min(maxi2[i + 1], list1[i])
	ans = []
	for i in range(1, n - 1):
		if maxi1[i - 1] < list1[i] > maxi2[i + 1]:
			for j in range(i):
				if list1[j] < list1[i]:
					ans.append(j + 1)
					break
			ans.append(i + 1)
			for j in range(i + 1, n):
				if list1[j] < list1[i]:
					ans.append(j + 1)
					break
			break
	if len(ans) > 0:
		print('YES')
		print(*ans)
	else:
		print('NO')
	t -= 1


t = int(input())
for z in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	found = False
	for i in range(n - 2):
		if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			found = True
			break
	if not found:
		print('NO')


number_of_testcase = int(input())
for _ in range(number_of_testcase):
	length = int(input())
	sequence_list = list(map(int, input().split()))
	for j in range(1, len(sequence_list) - 1):
		if sequence_list[j] > sequence_list[j - 1] and sequence_list[j] > sequence_list[j + 1]:
			print('Yes')
			print(j - 1 + 1, j + 1, j + 1 + 1)
			break
	else:
		print('No')


import os
os_input = os.read(0, int(10000000.0)).split()
os_input_pos = -1
answer_list = []

def read_s():
	global os_input_pos
	os_input_pos += 1
	return os_input[os_input_pos].decode()

def read_i():
	return int(read_s())

def write_s(v):
	answer_list.append(v)

def write_i(v):
	write_s(str(v))

def print_ans():
	os.write(1, '\n'.join(answer_list).encode())
	os.write(1, '\n'.encode())
from types import GeneratorType

def iterative(f, stack=[]):

	def wrapped_func(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		to = f(*args, **kwargs)
		while True:
			if type(to) is GeneratorType:
				stack.append(to)
				to = next(to)
			else:
				stack.pop()
				if not stack:
					break
				to = stack[-1].send(to)
		return to
	return wrapped_func
T = read_i()
while T:
	T -= 1
	n = read_i()
	a = [read_i() for i in range(n)]
	order = sorted([(g, i + 1) for (i, g) in enumerate(a)], reverse=True)
	l = 1
	r = n
	for (g, i) in order:
		if i != l and i != r:
			write_s('YES')
			write_s('{} {} {}'.format(l, i, r))
			break
		if i == l:
			l += 1
		else:
			r -= 1
	else:
		write_s('NO')
print_ans()


def ngr(arr):
	idx_ngr = []
	stack = []
	for idx in range(len(arr) - 1, -1, -1):
		if len(stack) == 0:
			idx_ngr.append(-1)
		elif stack and arr[stack[-1]] > arr[idx]:
			idx_ngr.append(stack[-1])
		elif stack and arr[stack[-1]] <= arr[idx]:
			while stack and arr[stack[-1]] <= arr[idx]:
				stack.pop()
			if stack:
				idx_ngr.append(stack[-1])
			else:
				idx_ngr.append(-1)
		stack.append(idx)
	return idx_ngr[::-1]

def nsr(arr):
	idx_nsr = []
	stack = []
	for idx in range(len(arr) - 1, -1, -1):
		if len(stack) == 0:
			idx_nsr.append(-1)
		elif stack and arr[stack[-1]] < arr[idx]:
			idx_nsr.append(stack[-1])
		elif stack and arr[stack[-1]] >= arr[idx]:
			while stack and arr[stack[-1]] >= arr[idx]:
				stack.pop()
			if stack:
				idx_nsr.append(stack[-1])
			else:
				idx_nsr.append(-1)
		stack.append(idx)
	return idx_nsr[::-1]
t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	idx_ngr = ngr(arr)
	idx_nsr = nsr(arr)
	for i in range(n):
		if idx_ngr[i] != -1 and idx_nsr[idx_ngr[i]] != -1:
			print('YES')
			print(i + 1, idx_ngr[i] + 1, idx_nsr[idx_ngr[i]] + 1)
			break
	else:
		print('NO')


import sys
input = sys.stdin.readline
T = int(input())
for _ in range(T):
	n = int(input())
	numbers = [int(inp) for inp in input().split(' ')]
	prefix_min = [100000]
	prefix_min_ids = [-1]
	for i in range(0, len(numbers) - 1, 1):
		if prefix_min[-1] > numbers[i]:
			prefix_min.append(numbers[i])
			prefix_min_ids.append(i)
		else:
			prefix_min.append(prefix_min[-1])
			prefix_min_ids.append(prefix_min_ids[-1])
	suffix_min = [100000]
	suffix_min_ids = [-1]
	for i in range(len(numbers) - 1, 0, -1):
		if suffix_min[-1] > numbers[i]:
			suffix_min.append(numbers[i])
			suffix_min_ids.append(i)
		else:
			suffix_min.append(suffix_min[-1])
			suffix_min_ids.append(suffix_min_ids[-1])
	suffix_min_ids = suffix_min_ids[::-1]
	suffix_min = suffix_min[::-1]
	for j in range(len(numbers)):
		if prefix_min[j] < numbers[j] and suffix_min[j] < numbers[j]:
			print('YES')
			print(prefix_min_ids[j] + 1, j + 1, suffix_min_ids[j] + 1)
			break
	if j == len(numbers) - 1:
		print('NO')


def three_indices(arr):
	l = []
	for i in range(len(arr) - 2):
		if arr[i + 1] > arr[i] and arr[i + 1] > arr[i + 2]:
			l.extend([i + 1, i + 2, i + 3])
			print('YES')
			break
	else:
		print('NO')
	return l
t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	result = three_indices(arr)
	if result:
		print(*result, sep=' ')


T = int(input())
for i in range(T):
	n = int(input())
	array = list(map(int, input().split()))
	flag = 0
	for x in range(1, n - 1):
		if array[x - 1] < array[x] and array[x] > array[x + 1]:
			flag = 1
			print('YES')
			print(x, x + 1, x + 2)
			break
	if flag == 0:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	ma = map(int, input().split())
	l = list(ma)
	if l == sorted(l) or l == sorted(l, reverse=True):
		print('no')
	else:
		for i in range(1, n):
			if l[i - 1] < l[i]:
				break
		for j in range(n - 1, 0, -1):
			if l[j] < l[j - 1]:
				break
		if i - 1 == j:
			print('no')
		else:
			print('yes')
			if l[i] < l[j - 1]:
				print(i, j, j + 1)
			else:
				print(i, i + 1, j + 1)


for _ in range(int(input())):
	n = int(input())
	li = list(map(int, input().split()))
	f = 1
	for x in range(1, n - 1):
		if li[x - 1] < li[x] > li[x + 1]:
			f = 0
			print('YES')
			print(x, x + 1, x + 2)
			break
	if f:
		print('NO')


tests = int(input())
sol = []
while tests:
	tests -= 1
	n = int(input())
	a = [int(i) for i in input().split()]
	ok = 'NO'
	d = [1]
	da = a[0]
	dr = True
	for i in range(1, n):
		if a[i] < a[d[len(d) - 1] - 1]:
			if not dr:
				d.append(i + 1)
				ok = 'YES'
				break
			else:
				d[0] = i + 1
		elif dr:
			dr = False
			d.append(i + 1)
		else:
			d[1] = i + 1
	if ok == 'NO':
		d = None
	sol.append((ok, d))
for i in sol:
	print(i[0])
	if i[1]:
		print(*i[1])


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	ans = []
	j = 0
	k = 2
	for i in range(1, n - 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			f = 1
			ans = [i - 1 + 1, i + 1, i + 1 + 1]
			break
	if f == 0:
		print('NO')
	else:
		print('YES')
		for i in ans:
			print(i, end=' ')
		print()


for _ in range(int(input())):
	nVal = int(input())
	permList = [int(x) for x in input().split()]
	flag = 0
	for i in range(1, len(permList) - 1):
		Lval = min(permList[0:i])
		Rval = min(permList[i + 1:])
		if permList[i] > Lval and permList[i] > Rval:
			flag = 1
			index1 = permList.index(Lval)
			index3 = permList.index(Rval)
			print('YES')
			print(index1 + 1, i + 1, index3 + 1)
			break
	if flag == 0:
		print('NO')


for t in range(int(input())):
	N = int(input())
	A = list(map(int, input().split()))
	flag = False
	for i in range(1, N - 1):
		if A[i - 1] < A[i] and A[i] > A[i + 1]:
			flag = True
			break
	if flag:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


import sys
input = lambda : sys.stdin.readline().rstrip()
for _ in range(int(input())):
	n = int(input())
	a = [int(i) - 1 for i in input().split()]
	save = [0] * n
	for i in range(n):
		save[a[i]] = i
	beg = 0
	end = n - 1
	got_it = -1
	while save:
		if save[-1] == beg:
			beg += 1
		elif save[-1] == end:
			end -= 1
		else:
			got_it = save[-1]
			break
		save.pop()
	if got_it == -1:
		print('NO')
	else:
		print('YES')
		print(a.index(min(a[:got_it])) + 1, got_it + 1, a.index(min(a[got_it + 1:])) + 1)


for t in range(int(input())):
	n = int(input())
	val = list(map(int, input().split()))
	answer_not_found = True
	for j in range(1, n - 1):
		if val[j - 1] < val[j] > val[j + 1]:
			print(f'YES\n{j} {j + 1} {j + 2}')
			answer_not_found = False
			break
	if answer_not_found:
		print('NO')


from sys import stdin
for _ in range(int(stdin.readline())):
	n = int(stdin.readline())
	arr = list(map(int, stdin.readline().split()))
	fl = 0
	for x in range(1, n - 1):
		if arr[x - 1] < arr[x] > arr[x + 1]:
			fl = 1
			(i, j, k) = (x - 1, x, x + 1)
			break
	if fl == 1:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


v = '1hivam kumar'.split(' ')
for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	x = 0
	y = 0
	z = 0
	c = 0
	r = n
	b = n
	while True:
		if b != p[c] and b != p[r - 1]:
			for i in range(c, r - 1):
				if b == p[i]:
					x = i
					y = i + 1
					z = i + 2
					break
		if b == p[c]:
			c = c + 1
			b = b - 1
		if b == p[r - 1]:
			r = r - 1
			b = b - 1
		if x != 0 and y != 0 and (z != 0):
			print('YES')
			print(x, y, z)
			break
		if r - c < 2:
			print('NO')
			break


n = int(input())
while n != 0:
	p = int(input())
	l = list(map(int, input().split()))
	(x, y, z) = (0, 0, 0)
	for i in range(len(l) - 2):
		(a, b, c) = (l[i], l[i + 1], l[i + 2])
		if a < b and b > c:
			(x, y, z) = (i, i + 1, i + 2)
	if x != y:
		print('YES')
		print(x + 1, ' ', y + 1, ' ', z + 1)
	else:
		print('NO')
	n -= 1


t = int(input())
for test in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	ans = []
	flag = 0
	for i in range(1, n - 1):
		l = i - 1
		r = i + 1
		while l >= 0 and a[l] > a[i]:
			l -= 1
		if l >= 0:
			while r < n and a[r] > a[i]:
				r += 1
			if r < n:
				ans += [l + 1, i + 1, r + 1]
				flag = 1
		if flag == 1:
			break
	if flag == 0:
		print('NO')
	else:
		print('YES')
		print(*ans)


t = int(input())
for _ in range(t):
	a = int(input())
	arr = list(map(int, input().split()))
	c = 0
	for i in range(1, a - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(str(i) + ' ' + str(i + 1) + ' ' + str(i + 2))
			c = 1
			break
	if c == 0:
		print('NO')


for t in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	d = 0
	for i in range(n - 2):
		if a[i] < a[i + 1] > a[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split(' ')))
	ans = -1
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			ans = i
			break
	if ans == -1:
		print('NO')
	else:
		print('yes')
		print(i, i + 1, i + 2)


TC = int(input())
for tc in range(TC):
	N = int(input())
	A = list(map(int, input().split()))
	i = 0
	j = len(A) - 1
	while i < len(A) and j >= 0:
		if A[i] == N:
			i += 1
			N -= 1
			continue
		if A[j] == N:
			j -= 1
			N -= 1
			continue
		break
	if i >= j or i >= len(A) or j < 0:
		print('NO')
	else:
		k = i
		for t in range(i + 1, j):
			if A[t] == N:
				k = t
				break
		print('YES')
		print(i + 1, k + 1, j + 1)


num = int(input())
for _ in range(num):
	n = int(input())
	p = [int(i) for i in input().split()]
	i = 0
	pre = [p[0]] * n
	pre2 = [0] * n
	suf = [p[-1]] * n
	suf2 = [n - 1] * n
	for i in range(n):
		if i != 0:
			pre[i] = min(pre[i - 1], p[i])
			if pre[i] == pre[i - 1]:
				pre2[i] = pre2[i - 1]
			else:
				pre2[i] = i
		if i != n:
			suf[-i - 1] = min(suf[-i], p[-i - 1])
			if suf[-i - 1] == p[-i - 1]:
				suf2[-i - 1] = n - i - 1
			else:
				suf2[-i - 1] = suf2[-i]
	for i in range(1, n - 1):
		if pre[i - 1] < p[i] and p[i] > suf[i + 1]:
			print('YES')
			print(pre2[i - 1] + 1, i + 1, suf2[i + 1] + 1)
			break
	else:
		print('NO')


import sys
reader = (s.rstrip() for s in sys.stdin)
input = reader.__next__
t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	loc = {}
	for (ind, val) in enumerate(arr):
		loc[val] = ind + 1
	(a, b, c) = (0, 0, 0)
	for x in range(1, n - 1):
		left = min(arr[:x])
		right = min(arr[x + 1:])
		if left < arr[x] > right:
			(a, b, c) = (loc[left], x + 1, loc[right])
			break
	if not a:
		print('NO')
	else:
		print('YES')
		print(a, b, c)


t = int(input())
for _ in range(t):
	n = int(input())
	p = [int(x) for x in input().split()]
	i = 0
	index = 1
	failed = False
	while p[index] < p[i]:
		i = index
		index += 1
		if index == n - 1:
			failed = True
			break
	if failed:
		print('NO')
		continue
	j = index
	index += 1
	while p[index] > p[j]:
		j = index
		index += 1
		if index == n:
			failed = True
			break
	if failed:
		print('NO')
	else:
		print('YES')
		print(i + 1, j + 1, index + 1)


t = int(input())
for _ in range(t):
	n = int(input())
	lst = list(map(int, input().split()))
	f = True
	for i in range(1, n - 1):
		if lst[i - 1] < lst[i] and lst[i] > lst[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			f = False
			break
	if f:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	p = [int(x) for x in input().split()]
	found = False
	for i in range(n - 2):
		if p[i + 1] > p[i]:
			found = True
			break
	if not found:
		print('NO')
	else:
		found = False
		for j in range(i + 1, n - 1):
			if p[j] > p[j + 1]:
				print('YES')
				print(i + 1, j + 1, j + 2)
				found = True
				break
		if not found:
			print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	flag = 0
	t = -1
	for i in range(n - 1):
		if p[i] < p[i + 1]:
			t = i
		if p[i] > p[i + 1] and t != -1:
			break
		if i == n - 2:
			print('NO')
			flag = 1
	if flag == 1:
		continue
	for i in range(t + 1, n - 1):
		if p[i] > p[i + 1]:
			s = i
			break
		if i == n - 2:
			print('NO')
			flag = 1
	if flag == 1:
		continue
	print('YES')
	print(t + 1)
	print(s + 1)
	print(s + 2)


import re
numTests = int(input())
testSet = []
for x in range(numTests):
	givenNums = []
	numI = 999999
	numJ = 999999
	numK = 999999
	increase = False
	currNum = 999999999
	first = True
	digits = int(input())
	digitList = input()
	digitList = re.split('\\s', digitList)
	for z in digitList:
		z = int(z)
		if first:
			first = False
		elif not increase:
			if z > currNum:
				increase = True
				numI = str(digitList.index(str(currNum)) + 1)
		elif z < currNum:
			numJ = str(digitList.index(str(currNum)) + 1)
			numK = str(digitList.index(str(z)) + 1)
			print('YES')
			print(numI + ' ' + numJ + ' ' + numK)
			break
		currNum = z
		if z == int(digitList[-1]):
			print('NO')


for i in range(int(input())):
	n = int(input())
	n1 = n
	l1 = list(map(int, input().split()))
	c1 = 0
	for j in range(n1):
		m1 = max(l1)
		if l1.index(m1) != 0 and l1.index(m1) != len(l1) - 1:
			print('YES')
			print(l1.index(m1) + c1, l1.index(m1) + c1 + 1, l1.index(m1) + 2 + c1)
			break
		elif l1.index(m1) == 0:
			c1 += 1
			l1.remove(m1)
		elif l1.index(m1) == len(l1) - 1:
			l1.remove(m1)
		if len(l1) < 3:
			print('NO')
			break


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	i = 1
	a = 0
	while i < n - 1:
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			a = 1
			break
		i += 1
	if not a:
		print('NO')


for i in range(int(input())):
	new = []
	n = int(input())
	arr = [int(i) for i in input().split()]
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] and arr[i] > arr[i + 1]:
			new.append(i)
			new.append(i + 1)
			new.append(i + 2)
			break
	if new == []:
		print('NO')
	else:
		print('YES')
		print(' '.join([str(i) for i in new]))


cases = int(input())
for t in range(cases):
	n = int(input())
	p = list(map(int, input().split()))
	f = 0
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			f = 1
			break
	if f == 0:
		print('NO')


import sys
RI = lambda : [int(x) for x in sys.stdin.readline().strip().split()]
rw = lambda : sys.stdin.readline().strip().split()
from math import *
t = int(input().strip())
for _ in range(t):
	n = int(input().strip())
	l = RI()
	d = {}
	for i in range(n):
		d[l[i]] = i
	minarr = [0] * n
	mini = float('inf')
	for i in range(0, n):
		minarr[i] = mini
		mini = min(mini, l[i])
	minarr2 = [0] * n
	mini2 = float('inf')
	for i in range(n - 1, -1, -1):
		minarr2[i] = mini2
		mini2 = min(mini2, l[i])
	f = 0
	for i in range(1, n):
		if minarr[i] < l[i] and minarr2[i] < l[i]:
			print('YES')
			print(d[minarr[i]] + 1, i + 1, d[minarr2[i]] + 1)
			f = 1
			break
	if f == 0:
		print('NO')


import sys
import math
import bisect
from sys import stdin, stdout
from math import gcd, floor, sqrt, log
from collections import defaultdict as dd
from bisect import bisect_left as bl, bisect_right as br
from collections import Counter
inp = lambda : int(input())
strng = lambda : input().strip()
jn = lambda x, l: x.join(map(str, l))
strl = lambda : list(input().strip())
mul = lambda : map(int, input().strip().split())
mulf = lambda : map(float, input().strip().split())
seq = lambda : list(map(int, input().strip().split()))
ceil = lambda x: int(x) if x == int(x) else int(x) + 1
ceildiv = lambda x, d: x // d if x % d == 0 else x // d + 1
flush = lambda : stdout.flush()
stdstr = lambda : stdin.readline()
stdint = lambda : int(stdin.readline())
stdpr = lambda x: stdout.write(str(x))
stdarr = lambda : map(int, stdstr().split())
mod = 1000000007
for _ in range(stdint()):
	n = stdint()
	arr = list(stdarr())
	inc = []
	dec = []
	for i in range(n - 2):
		f = arr[i]
		s = arr[i + 1]
		t = arr[i + 2]
		if f < s and s > t:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


t = int(input())
while t:
	c = 0
	n = int(input())
	lst = list(map(int, input().split()))
	for i in range(n - 2):
		if lst[i] < lst[i + 1] > lst[i + 2]:
			print('Yes')
			print(i + 1, i + 2, i + 3)
			c = 1
			break
	if c == 0:
		print('No')
	t = t - 1


cases = int(input())
for i in range(cases):
	n = int(input())
	l2 = input().split(' ')
	arr = []
	found = False
	for a in l2:
		arr.append(int(a))
	for b in range(len(arr) - 2):
		ele1 = arr[b]
		ele2 = arr[b + 1]
		ele3 = arr[b + 2]
		if ele2 > ele1 and ele2 > ele3:
			i1 = b + 1
			i2 = b + 2
			i3 = b + 3
			print('YES')
			print(i1, i2, i3)
			found = True
			break
	if not found:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	s = input()
	arr = [int(x) for x in s.split()]
	ind = -1
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] and arr[i + 1] < arr[i]:
			ind = i
			break
	if ind != -1:
		print('YES')
		print(ind, ind + 1, ind + 2)
	else:
		print('NO')


t = int(input())
for a0 in range(t):
	n = int(input())
	l = [int(i) for i in input().split()]
	f = 0
	for i in range(n - 2):
		if l[i] < l[i + 1] and l[i + 1] > l[i + 2]:
			f = 1
			break
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(i + 1, i + 2, i + 3)


for test in range(0, int(input())):
	n = int(input())
	arr = [int(x) for x in input().split()]
	key = 0
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			key = 1
			break
	if key == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = [int(i) for i in input().split()][:n]
	for i in range(len(l)):
		first = i
		(second, third) = (-1, -1)
		for j in range(i + 1, len(l)):
			if second == -1:
				if l[j] > l[first]:
					second = j
			elif l[j] < l[second]:
				third = j
				print('YES')
				print(first + 1, second + 1, third + 1)
				break
		else:
			continue
		break
	else:
		print('NO')


t = int(input())

def checkio(arr):
	for i in range(1, len(arr) - 1, 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
for _ in range(t):
	n = int(input())
	sequence = list(map(int, input().split(' ')))
	checkio(sequence)


MOD = 1000000007
ii = lambda : int(input())
si = lambda : input()
dgl = lambda : list(map(int, input()))
f = lambda : map(int, input().split())
il = lambda : list(map(int, input().split()))
ls = lambda : list(input())
from collections import *
for _ in range(ii()):
	n = ii()
	a = il()
	c = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			c = c + 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if c == 0:
		print('NO')


T = int(input())
while T > 0:
	n = int(input())
	arr = list(map(int, input().split()))
	index = [0] * (n + 1)
	for i in range(n):
		index[arr[i]] = i
	forb1 = 0
	forb2 = n - 1
	find = -1
	for i in range(n, 0, -1):
		if index[i] == forb1:
			forb1 += 1
		elif index[i] == forb2:
			forb2 -= 1
		else:
			find = i
			break
	if find == -1:
		print('NO')
	else:
		print('YES')
		print(str(forb1 + 1) + ' ' + str(index[find] + 1) + ' ' + str(forb2 + 1))
	T -= 1


def solve(L):
	for j in range(1, len(L) - 1):
		if L[j] > L[j - 1] and L[j] > L[j + 1]:
			return str(j) + ' ' + str(j + 1) + ' ' + str(j + 2)
	return 0
T = int(input())
for i in range(1, T + 1):
	n = int(input())
	L = [int(x) for x in input().split()]
	if type(solve(L)) is str:
		print('YES')
		print(solve(L))
	elif type(solve(L)) is int:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
import threading
from bisect import bisect_right
from math import gcd, log
from collections import defaultdict

def main():
	for _ in range(int(input())):
		n = int(input())
		arr = list(map(lambda x: int(x) - 1, input().split()))
		start = 0
		end = n - 1
		ind = list(range(0, n))
		ind.sort(key=lambda x: arr[x])
		while True:
			if start >= end:
				print('NO')
				break
			else:
				i = ind.pop()
				if i == start:
					start += 1
				elif i == end:
					end -= 1
				else:
					print('YES')
					print(start + 1, i + 1, end + 1)
					break
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')
main()


for ty in range(int(input())):
	n = int(input())
	t = n
	s = input().split()
	l = []
	for i in s:
		l += [int(i)]
	lc = 0
	rc = len(l) - 1
	j = l.index(t)
	while (j == lc or j == rc) and t > 0:
		t = t - 1
		if j == lc:
			lc += 1
		else:
			rc -= 1
		if t == 0:
			print('NO')
			break
		j = l.index(t)
	if t != 0:
		print('YES')
		print(str(j) + ' ' + str(j + 1) + ' ' + str(j + 2))


total = int(input())
while total:
	n = int(input())
	l = [int(i) for i in input().split()]
	k = l[:]
	l.sort()
	if l == list(range(1, n + 1)):
		for j in range(1, n + 1):
			try:
				if k[j] > k[j - 1] and k[j] > k[j + 1]:
					print('YES')
					f = True
					print(j, j + 1, j + 2)
					break
				else:
					f = False
			except:
				pass
	if l != list(range(1, n + 1)) or f == False:
		print('NO')
	total -= 1


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	p = []
	f = False
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			f = True
			p += [i, i + 1, i + 2]
			break
	if f == False:
		print('NO')
	else:
		print('YES')
		print(*p)


for _ in range(int(input())):
	n = int(input())
	ls = list(map(int, input().split()))
	case = 0
	for i in range(1, n - 1):
		ans = [-1, -1, -1]
		for j in range(i + 1, n):
			if ls[i] > ls[j]:
				ans[2] = j + 1
				break
		for x in range(i):
			if ls[i] > ls[x]:
				ans[0] = x + 1
				break
		if ans[0] != -1 and ans[2] != -1:
			case = 1
			ans[1] = i + 1
			break
	if case:
		print('YES')
		print(*ans)
	else:
		print('NO')


from sys import stdin, stdout
import math
input = stdin.readline

def print(x='', y='', end='\n'):
	if y == '':
		stdout.write(str(x) + end)
	else:
		stdout.write(str(x) + ' ' + str(y) + end)

def solve():
	n = int(input())
	l = list(map(int, input().split()))
	for j in range(1, n - 1):
		(f1, f2) = (0, 0)
		for i in range(j):
			if l[i] < l[j]:
				f1 = 1
				break
		for k in range(j + 1, n):
			if l[k] < l[j]:
				f2 = 1
				break
		if f1 and f2:
			print('YES')
			print(i + 1, j + 1, end=' ')
			print(k + 1)
			return
	print('NO')
tt = 1
tt = int(input())
for __ in range(tt):
	solve()


import sys
INF = 10 ** 20
MOD = 10 ** 9 + 7
I = lambda : list(map(int, input().split()))
from math import gcd
from math import ceil
from collections import defaultdict as dd, Counter
from bisect import bisect_left as bl, bisect_right as br

def solve():
	(n,) = I()
	a = I()
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
(t,) = I()
while t:
	t -= 1
	solve()


import sys
input = sys.stdin.readline
T = int(input())
for t in range(T):
	N = int(input())
	P = [int(_) for _ in input().split()]
	pos = {}
	imin = 0
	imax = N - 1
	for (i, el) in enumerate(P):
		pos[el] = i
	for el in range(N, 0, -1):
		if pos[el] == imin:
			imin += 1
		elif pos[el] == imax:
			imax -= 1
		else:
			print('YES')
			print(pos[el], pos[el] + 1, pos[el] + 2)
			break
	else:
		print('NO')


from math import inf, log2

class SegmentTree:

	def __init__(self, array, func=max):
		self.n = len(array)
		self.size = 2 ** (int(log2(self.n - 1)) + 1) if self.n != 1 else 1
		self.func = func
		self.default = 0 if self.func != min else inf
		self.data = [self.default] * (2 * self.size)
		self.process(array)

	def process(self, array):
		self.data[self.size:self.size + self.n] = array
		for i in range(self.size - 1, -1, -1):
			self.data[i] = self.func(self.data[2 * i], self.data[2 * i + 1])

	def query(self, alpha, omega):
		if alpha == omega:
			return self.data[alpha + self.size]
		res = self.default
		alpha += self.size
		omega += self.size + 1
		while alpha < omega:
			if alpha & 1:
				res = self.func(res, self.data[alpha])
				alpha += 1
			if omega & 1:
				omega -= 1
				res = self.func(res, self.data[omega])
			alpha >>= 1
			omega >>= 1
		return res

	def update(self, index, value):
		index += self.size
		self.data[index] = value
		index >>= 1
		while index:
			self.data[index] = self.func(self.data[2 * index], self.data[2 * index + 1])
			index >>= 1
import os
import sys
from io import BytesIO, IOBase
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')
from math import gcd, ceil

def pre(s):
	n = len(s)
	pi = [0] * n
	for i in range(1, n):
		j = pi[i - 1]
		while j and s[i] != s[j]:
			j = pi[j - 1]
		if s[i] == s[j]:
			j += 1
		pi[i] = j
	return pi

def prod(a):
	ans = 1
	for each in a:
		ans = ans * each
	return ans

def lcm(a, b):
	return a * b // gcd(a, b)

def binary(x, length=16):
	y = bin(x)[2:]
	return y if len(y) >= length else '0' * (length - len(y)) + y
from collections import deque
for _ in range(int(input()) if True else 1):
	n = int(input())
	a = list(map(int, input().split()))
	st1 = SegmentTree(a, func=min)
	found = False
	for i in range(1, n - 1):
		if st1.query(0, i - 1) < a[i] > st1.query(i + 1, n - 1):
			print('YES')
			print(a.index(st1.query(0, i - 1)) + 1, i + 1, a.index(st1.query(i + 1, n - 1)) + 1)
			found = True
			break
	if not found:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	flag = False
	ans = []
	for i in range(len(a) - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			flag = True
			break
	if not flag:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	cou = 0
	i = 0
	while i < n - 2:
		if a[i] < a[i + 1] and a[i + 2] < a[i + 1]:
			cou = 1
			break
		i += 1
	if cou == 1:
		print('YES')
		print(i + 1, i + 2, i + 3)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	f = 1
	x = list(map(int, input().split()))
	for i in range(1, n):
		(a, b) = (min(x[:i + 1]), min(x[i:]))
		if a < x[i] > b:
			print('YES')
			print(x.index(a) + 1, i + 1, x.index(b) + 1)
			f = 0
			break
	if f:
		print('NO')


import bisect
import decimal
from decimal import Decimal
import os
from collections import Counter
import bisect
from collections import defaultdict
import math
import random
import heapq
from math import sqrt
import sys
from functools import reduce, cmp_to_key
from collections import deque
import threading
from itertools import combinations
from io import BytesIO, IOBase
from itertools import accumulate
decimal.getcontext().prec = 46

def primeFactors(n):
	prime = set()
	while n % 2 == 0:
		prime.add(2)
		n = n // 2
	for i in range(3, int(math.sqrt(n)) + 1, 2):
		while n % i == 0:
			prime.add(i)
			n = n // i
	if n > 2:
		prime.add(n)
	return list(prime)

def getFactors(n):
	factors = []
	i = 1
	while i <= math.sqrt(n):
		if n % i == 0:
			if n // i == i:
				factors.append(i)
			else:
				factors.append(i)
				factors.append(n // i)
		i = i + 1
	return factors

def modefiedSieve():
	mx = 10 ** 7 + 1
	sieve = [-1] * mx
	for i in range(2, mx):
		if sieve[i] == -1:
			sieve[i] = i
			for j in range(i * i, mx, i):
				if sieve[j] == -1:
					sieve[j] = i
	return sieve

def SieveOfEratosthenes(n):
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	num = []
	for p in range(2, n + 1):
		if prime[p]:
			num.append(p)
	return num

def lcm(a, b):
	return a * b // math.gcd(a, b)

def sort_dict(key_value):
	return sorted(key_value.items(), key=lambda kv: (kv[1], kv[0]), reverse=True)

def list_input():
	return list(map(int, input().split()))

def num_input():
	return map(int, input().split())

def string_list():
	return list(input())

def decimalToBinary(n):
	return bin(n).replace('0b', '')

def binaryToDecimal(n):
	return int(n, 2)

def DFS(n, s, adj):
	visited = [False for i in range(n + 1)]
	stack = []
	stack.append(s)
	while len(stack):
		s = stack[-1]
		stack.pop()
		if not visited[s]:
			visited[s] = True
		for node in adj[s]:
			if not visited[node]:
				stack.append(node)

def maxSubArraySum(a, size):
	maxint = 10 ** 10
	max_so_far = -maxint - 1
	max_ending_here = 0
	for i in range(0, size):
		max_ending_here = max_ending_here + a[i]
		if max_so_far < max_ending_here:
			max_so_far = max_ending_here
		if max_ending_here < 0:
			max_ending_here = 0
	return max_so_far

def lis(arr):
	n = len(arr)
	lis = [1] * n
	for i in range(1, n):
		for j in range(0, i):
			if arr[i] >= arr[j] and lis[i] < lis[j] + 1:
				lis[i] = lis[j] + 1
	maximum = 0
	for i in range(n):
		maximum = max(maximum, lis[i])
	return maximum

def solve():
	n = int(input())
	arr = list_input()
	(minn, left) = (10 ** 10, -1)
	(maxx, right) = (0, -1)
	curr = -1
	for i in range(1, n - 1):
		if arr[i - 1] < minn:
			minn = arr[i - 1]
			left = i - 1
		maxx = arr[i + 1]
		right = i + 1
		if arr[i] > minn and arr[i] > maxx:
			curr = i
			break
	if curr == -1 or left == -1 or right == -1:
		print('NO')
	else:
		print('YES')
		print(left + 1, curr + 1, right + 1)
t = 1
t = int(input())
for _ in range(t):
	solve()


from collections import deque
from collections import OrderedDict
import math
import sys
import os
import threading
import bisect
import operator
import heapq
from atexit import register
from io import BytesIO
import io
input = lambda : sys.stdin.readline().rstrip('\r\n')
for t in range(int(input())):
	n = int(input())
	arr = [0] + list(map(int, input().split()))
	dpl = [1005] * 1005
	dpr = [1005] * 1005
	for i in range(1, n + 1):
		dpl[i] = min(dpl[i - 1], arr[i])
	for i in range(n, 0, -1):
		dpr[i] = min(dpr[i + 1], arr[i])
	for i in range(1, n + 1):
		if dpl[i] < arr[i] and dpr[i] < arr[i]:
			print('YES')
			for j in range(i):
				if arr[j] == dpl[i]:
					print(j, end=' ')
			print(i, end=' ')
			for j in range(i + 1, n + 1):
				if arr[j] == dpr[i]:
					print(j)
			break
	else:
		print('NO')


(t, o) = (int(input()), list())
for q in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	a = 'NO'
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1] and (a == 'NO'):
			a = 'YES'
			o.append('YES')
			o.append(str(i) + ' ' + str(i + 1) + ' ' + str(i + 2))
	if a != 'YES':
		o.append('NO')
for x in o:
	print(x)


from __future__ import division, print_function
import os, sys
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
	from __builtin__ import xrange as range
	from future_builtins import ascii, filter, hex, map, oct, zip

def ii():
	return int(input())

def si():
	return input()

def mi():
	return map(int, input().strip().split(' '))

def msi():
	return map(str, input().strip().split(' '))

def li():
	return list(mi())

def dmain():
	sys.setrecursionlimit(1000000)
	threading.stack_size(1024000)
	thread = threading.Thread(target=main)
	thread.start()
import sys
input = sys.stdin.readline
scanner = lambda : int(input())
string = lambda : input().rstrip()
get_list = lambda : list(read())
read = lambda : map(int, input().split())
get_float = lambda : map(float, input().split())

def ceil(x):
	if x != int(x):
		x = int(x) + 1
	return x

def factorial(x, m):
	val = 1
	while x > 0:
		val = val * x % m
		x -= 1
	return val

def fact(x):
	val = 1
	while x > 0:
		val *= x
		x -= 1
	return val

def swaparr(arr, a, b):
	temp = arr[a]
	arr[a] = arr[b]
	arr[b] = temp

def gcd(a, b):
	if b == 0:
		return a
	return gcd(b, a % b)

def lcm(a, b):
	return a * b // math.gcd(a, b)

def is_integer(n):
	return math.ceil(n) == math.floor(n)

def nCr(n, k):
	if k > n:
		return 0
	if k > n - k:
		k = n - k
	res = 1
	for i in range(k):
		res = res * (n - i)
		res = res / (i + 1)
	return int(res)

def primefs(n):
	primes = {}
	while n % 2 == 0 and n > 0:
		primes[2] = primes.get(2, 0) + 1
		n = n // 2
	for i in range(3, int(n ** 0.5) + 2, 2):
		while n % i == 0 and n > 0:
			primes[i] = primes.get(i, 0) + 1
			n = n // i
	if n > 2:
		primes[n] = primes.get(n, 0) + 1
	return primes

def power(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def swap(a, b):
	temp = a
	a = b
	b = temp
	return (a, b)

def find(x, link):
	p = x
	while p != link[p]:
		p = link[p]
	while x != p:
		nex = link[x]
		link[x] = p
		x = nex
	return p

def union(x, y, link, size):
	x = find(x, link)
	y = find(y, link)
	if size[x] < size[y]:
		(x, y) = swap(x, y)
	if x != y:
		size[x] += size[y]
		link[y] = x

def sieve(n):
	prime = [True for i in range(n + 1)]
	(prime[0], prime[1]) = (False, False)
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	return prime

def phi(n):
	result = n
	p = 2
	while p * p <= n:
		if n % p == 0:
			while n % p == 0:
				n = n // p
			result = result * (1.0 - 1.0 / float(p))
		p = p + 1
	if n > 1:
		result = result * (1.0 - 1.0 / float(n))
	return int(result)

def is_prime(n):
	if n == 0:
		return False
	if n == 1:
		return True
	for i in range(2, int(n ** (1 / 2)) + 1):
		if not n % i:
			return False
	return True

def next_prime(n, primes):
	while primes[n] != True:
		n += 1
	return n
MAXN = int(100000.0 + 5)

def spf_sieve():
	spf[1] = 1
	for i in range(2, MAXN):
		spf[i] = i
	for i in range(4, MAXN, 2):
		spf[i] = 2
	for i in range(3, ceil(MAXN ** 0.5), 2):
		if spf[i] == i:
			for j in range(i * i, MAXN, i):
				if spf[j] == j:
					spf[j] = i
spf = [0 for i in range(MAXN)]

def factoriazation(x):
	res = []
	for i in range(2, int(x ** 0.5) + 1):
		while x % i == 0:
			res.append(i)
			x //= i
	if x != 1:
		res.append(x)
	return res

def factors(n):
	res = []
	for i in range(1, int(n ** 0.5) + 1):
		if n % i == 0:
			res.append(i)
			res.append(n // i)
	return list(set(res))

def int_array():
	return list(map(int, input().strip().split()))

def float_array():
	return list(map(float, input().strip().split()))

def str_array():
	return input().strip().split()

def binary_search(low, high, w, h, n):
	while low < high:
		mid = low + (high - low) // 2
		if check(mid, w, h, n):
			low = mid + 1
		else:
			high = mid
	return low

def check(beauty, s, n, count):
	pass
MOD = int(1000000000.0) + 7
CMOD = 998244353
INF = float('inf')
NINF = -float('inf')
alphs = 'abcdefghijklmnopqrstuvwxyz'
from itertools import permutations
import math
import bisect as bis
import random
import sys
import collections as collect

def solve():
	n = scanner()
	p = get_list()
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
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')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
for i in range(scanner()):
	solve()


for _ in range(int(input())):
	n = int(input())
	a = [*map(int, input().split())]
	ans = []
	for i in range(n - 2):
		if a[i] > a[i + 1]:
			continue
		for j in range(i + 1, n - 1):
			if a[j] < a[j + 1]:
				continue
			for k in range(j + 1, n):
				if k < n and a[i] < a[j] and (a[k] < a[j]):
					ans = [i + 1, j + 1, k + 1]
					break
			if ans:
				break
		if ans:
			break
	if ans:
		print('YES')
		print(*ans)
	else:
		print('NO')


tc = int(input())
for _ in range(tc):
	n = int(input())
	l = input().rstrip().split()
	(i, j) = (None, None)
	(a, b) = (None, None)
	for (idx, val) in enumerate(map(int, l)):
		if not i:
			(i, a) = (idx + 1, val)
		elif not j:
			if val > a:
				(j, b) = (idx + 1, val)
			else:
				(i, a) = (idx + 1, val)
		elif val < b:
			print('YES')
			print(i, j, idx + 1)
			break
		else:
			(j, b) = (idx + 1, val)
	else:
		print('NO')


import io
import os
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
from sys import stdout

def solve():
	n = int(input())
	a = list(map(int, input().split()))
	flag = 0
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			stdout.write('YES\n')
			print(i, i + 1, i + 2)
			flag = 1
			break
	if flag == 0:
		stdout.write('NO\n')

def main():
	for t in range(int(input())):
		solve()
main()


t = int(input())
for _ in range(t):
	n = int(input())
	arr = [int(x) for x in input().split()]
	a = b = c = None
	minIdx = 0
	maxLargerIdxAfterMinIdx = -1
	for i in range(n):
		if maxLargerIdxAfterMinIdx == -1 and arr[i] < arr[minIdx]:
			minIdx = i
		elif maxLargerIdxAfterMinIdx == -1 and arr[i] > arr[minIdx]:
			maxLargerIdxAfterMinIdx = i
			a = minIdx
		elif maxLargerIdxAfterMinIdx != -1 and arr[i] > arr[maxLargerIdxAfterMinIdx]:
			maxLargerIdxAfterMinIdx = i
		elif maxLargerIdxAfterMinIdx != -1 and arr[i] < arr[maxLargerIdxAfterMinIdx]:
			b = maxLargerIdxAfterMinIdx
			c = i
			break
	if c != None:
		print('YES')
		print('{} {} {}'.format(a + 1, b + 1, c + 1))
	else:
		print('NO')


import math
import sys

def dict_sort(ans):
	ans = sorted(ans.items(), reverse=True, key=lambda kv: kv[1])

def seive_primes(n):
	flag = [0] * (n + 1)
	flag[1] = flag[0] = 1
	i = 2
	while i * i <= n:
		if flag[i] == 0:
			j = i * i
			while j < n + 1:
				flag[j] = 1
				j += i
		i += 1
	return flag

def is_prime(n):
	if n == 1:
		return 0
	for i in range(2, int(math.sqrt(n)) + 1):
		if n % i == 0:
			return False
	return True

def gcd(a, b):
	if b == 0:
		return a
	return gcd(b, a % b)

def lcm(a, b):
	return a * b // gcd(a, b)

def fact(n):
	if n == 1:
		return n
	return fact(n - 1) * n

def pow_2s(n):
	ls = []
	for i in range(1, n + 1):
		ls.append(2 ** i)
	return ls

def alphbates():
	return 'abcdefghijklmnopqrstuvwxyz'

def inp():
	ls = list(map(int, input().split()))
	return ls

def mult_inp():
	return map(int, input().split())
t = int(input())
for _ in range(t):
	n = int(input())
	ls = inp()
	flag = 1
	for i in range(1, n - 1):
		if ls[i] > ls[i + 1] and ls[i] > ls[i - 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = 0
			break
	if flag == 1:
		print('NO')


def sol(arr: list) -> tuple:
	minl = []
	prev = float('inf')
	for i in arr:
		prev = min(prev, i)
		minl.append(prev)
	minr = []
	prev = float('inf')
	for i in reversed(arr):
		prev = min(prev, i)
		minr.append(prev)
	minr.reverse()
	for i in range(len(arr)):
		if minl[i] < arr[i] and arr[i] > minr[i]:
			for l in range(i):
				if arr[l] < arr[i]:
					break
			for r in range(i, len(arr)):
				if arr[r] < arr[i]:
					break
			return [l, i, r]
	else:
		return []
T = int(input())
tmp = []
p = print
for _ in range(T):
	n = input()
	row = [*map(int, input().split(' '))]
	out = sol(row)
	if out:
		print('YES')
		(i, j, k) = out
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


import math
import heapq, bisect
import sys
from collections import deque, defaultdict
from fractions import Fraction
mod = 10 ** 9 + 7
mod1 = 998244353
import os
import sys
from io import BytesIO, IOBase
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')

class TreeNode:

	def __init__(self, k, v):
		self.key = k
		self.value = v
		self.left = None
		self.right = None
		self.parent = None
		self.height = 1
		self.num_left = 1
		self.num_total = 1

class AvlTree:

	def __init__(self):
		self._tree = None

	def add(self, k, v):
		if not self._tree:
			self._tree = TreeNode(k, v)
			return
		node = self._add(k, v)
		if node:
			self._rebalance(node)

	def _add(self, k, v):
		node = self._tree
		while node:
			if k < node.key:
				if node.left:
					node = node.left
				else:
					node.left = TreeNode(k, v)
					node.left.parent = node
					return node.left
			elif node.key < k:
				if node.right:
					node = node.right
				else:
					node.right = TreeNode(k, v)
					node.right.parent = node
					return node.right
			else:
				node.value = v
				return

	@staticmethod
	def get_height(x):
		return x.height if x else 0

	@staticmethod
	def get_num_total(x):
		return x.num_total if x else 0

	def _rebalance(self, node):
		n = node
		while n:
			lh = self.get_height(n.left)
			rh = self.get_height(n.right)
			n.height = max(lh, rh) + 1
			balance_factor = lh - rh
			n.num_total = 1 + self.get_num_total(n.left) + self.get_num_total(n.right)
			n.num_left = 1 + self.get_num_total(n.left)
			if balance_factor > 1:
				if self.get_height(n.left.left) < self.get_height(n.left.right):
					self._rotate_left(n.left)
				self._rotate_right(n)
			elif balance_factor < -1:
				if self.get_height(n.right.right) < self.get_height(n.right.left):
					self._rotate_right(n.right)
				self._rotate_left(n)
			else:
				n = n.parent

	def _remove_one(self, node):
		replacement = node.left or node.right
		if node.parent:
			if AvlTree._is_left(node):
				node.parent.left = replacement
			else:
				node.parent.right = replacement
			replacement.parent = node.parent
			node.parent = None
		else:
			self._tree = replacement
			replacement.parent = None
		node.left = None
		node.right = None
		node.parent = None
		self._rebalance(replacement)

	def _remove_leaf(self, node):
		if node.parent:
			if AvlTree._is_left(node):
				node.parent.left = None
			else:
				node.parent.right = None
			self._rebalance(node.parent)
		else:
			self._tree = None
		node.parent = None
		node.left = None
		node.right = None

	def remove(self, k):
		node = self._get_node(k)
		if not node:
			return
		if AvlTree._is_leaf(node):
			self._remove_leaf(node)
			return
		if node.left and node.right:
			nxt = AvlTree._get_next(node)
			node.key = nxt.key
			node.value = nxt.value
			if self._is_leaf(nxt):
				self._remove_leaf(nxt)
			else:
				self._remove_one(nxt)
			self._rebalance(node)
		else:
			self._remove_one(node)

	def get(self, k):
		node = self._get_node(k)
		return node.value if node else -1

	def _get_node(self, k):
		if not self._tree:
			return None
		node = self._tree
		while node:
			if k < node.key:
				node = node.left
			elif node.key < k:
				node = node.right
			else:
				return node
		return None

	def get_at(self, pos):
		x = pos + 1
		node = self._tree
		while node:
			if x < node.num_left:
				node = node.left
			elif node.num_left < x:
				x -= node.num_left
				node = node.right
			else:
				return (node.key, node.value)
		raise IndexError('Out of ranges')

	@staticmethod
	def _is_left(node):
		return node.parent.left and node.parent.left == node

	@staticmethod
	def _is_leaf(node):
		return node.left is None and node.right is None

	def _rotate_right(self, node):
		if not node.parent:
			self._tree = node.left
			node.left.parent = None
		elif AvlTree._is_left(node):
			node.parent.left = node.left
			node.left.parent = node.parent
		else:
			node.parent.right = node.left
			node.left.parent = node.parent
		bk = node.left.right
		node.left.right = node
		node.parent = node.left
		node.left = bk
		if bk:
			bk.parent = node
		node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
		node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
		node.num_left = 1 + self.get_num_total(node.left)

	def _rotate_left(self, node):
		if not node.parent:
			self._tree = node.right
			node.right.parent = None
		elif AvlTree._is_left(node):
			node.parent.left = node.right
			node.right.parent = node.parent
		else:
			node.parent.right = node.right
			node.right.parent = node.parent
		bk = node.right.left
		node.right.left = node
		node.parent = node.right
		node.right = bk
		if bk:
			bk.parent = node
		node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
		node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
		node.num_left = 1 + self.get_num_total(node.left)

	@staticmethod
	def _get_next(node):
		if not node.right:
			return node.parent
		n = node.right
		while n.left:
			n = n.left
		return n
avl = AvlTree()

class SegmentTree1:

	def __init__(self, data, default='z', func=lambda a, b: min(a, b)):
		self._default = default
		self._func = func
		self._len = len(data)
		self._size = _size = 1 << (self._len - 1).bit_length()
		self.data = [default] * (2 * _size)
		self.data[_size:_size + self._len] = data
		for i in reversed(range(_size)):
			self.data[i] = func(self.data[i + i], self.data[i + i + 1])

	def __delitem__(self, idx):
		self[idx] = self._default

	def __getitem__(self, idx):
		return self.data[idx + self._size]

	def __setitem__(self, idx, value):
		idx += self._size
		self.data[idx] = value
		idx >>= 1
		while idx:
			self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
			idx >>= 1

	def __len__(self):
		return self._len

	def query(self, start, stop):
		if start == stop:
			return self.__getitem__(start)
		stop += 1
		start += self._size
		stop += self._size
		res = self._default
		while start < stop:
			if start & 1:
				res = self._func(res, self.data[start])
				start += 1
			if stop & 1:
				stop -= 1
				res = self._func(res, self.data[stop])
			start >>= 1
			stop >>= 1
		return res

	def __repr__(self):
		return 'SegmentTree({0})'.format(self.data)

class SegmentTree:

	def __init__(self, data, default=0, func=lambda a, b: a + b):
		self._default = default
		self._func = func
		self._len = len(data)
		self._size = _size = 1 << (self._len - 1).bit_length()
		self.data = [default] * (2 * _size)
		self.data[_size:_size + self._len] = data
		for i in reversed(range(_size)):
			self.data[i] = func(self.data[i + i], self.data[i + i + 1])

	def __delitem__(self, idx):
		self[idx] = self._default

	def __getitem__(self, idx):
		return self.data[idx + self._size]

	def __setitem__(self, idx, value):
		idx += self._size
		self.data[idx] = value
		idx >>= 1
		while idx:
			self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
			idx >>= 1

	def __len__(self):
		return self._len

	def query(self, start, stop):
		if start == stop:
			return self.__getitem__(start)
		stop += 1
		start += self._size
		stop += self._size
		res = self._default
		while start < stop:
			if start & 1:
				res = self._func(res, self.data[start])
				start += 1
			if stop & 1:
				stop -= 1
				res = self._func(res, self.data[stop])
			start >>= 1
			stop >>= 1
		return res

	def __repr__(self):
		return 'SegmentTree({0})'.format(self.data)

class Factorial:

	def __init__(self, MOD):
		self.MOD = MOD
		self.factorials = [1, 1]
		self.invModulos = [0, 1]
		self.invFactorial_ = [1, 1]

	def calc(self, n):
		if n <= -1:
			print('Invalid argument to calculate n!')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		if n < len(self.factorials):
			return self.factorials[n]
		nextArr = [0] * (n + 1 - len(self.factorials))
		initialI = len(self.factorials)
		prev = self.factorials[-1]
		m = self.MOD
		for i in range(initialI, n + 1):
			prev = nextArr[i - initialI] = prev * i % m
		self.factorials += nextArr
		return self.factorials[n]

	def inv(self, n):
		if n <= -1:
			print('Invalid argument to calculate n^(-1)')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		p = self.MOD
		pi = n % p
		if pi < len(self.invModulos):
			return self.invModulos[pi]
		nextArr = [0] * (n + 1 - len(self.invModulos))
		initialI = len(self.invModulos)
		for i in range(initialI, min(p, n + 1)):
			next = -self.invModulos[p % i] * (p // i) % p
			self.invModulos.append(next)
		return self.invModulos[pi]

	def invFactorial(self, n):
		if n <= -1:
			print('Invalid argument to calculate (n^(-1))!')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		if n < len(self.invFactorial_):
			return self.invFactorial_[n]
		self.inv(n)
		nextArr = [0] * (n + 1 - len(self.invFactorial_))
		initialI = len(self.invFactorial_)
		prev = self.invFactorial_[-1]
		p = self.MOD
		for i in range(initialI, n + 1):
			prev = nextArr[i - initialI] = prev * self.invModulos[i % p] % p
		self.invFactorial_ += nextArr
		return self.invFactorial_[n]

class Combination:

	def __init__(self, MOD):
		self.MOD = MOD
		self.factorial = Factorial(MOD)

	def ncr(self, n, k):
		if k < 0 or n < k:
			return 0
		k = min(k, n - k)
		f = self.factorial
		return f.calc(n) * f.invFactorial(max(n - k, k)) * f.invFactorial(min(k, n - k)) % self.MOD

def powm(a, n, m):
	if a == 1 or n == 0:
		return 1
	if n % 2 == 0:
		s = powm(a, n // 2, m)
		return s * s % m
	else:
		return a * powm(a, n - 1, m) % m

def sort_list(list1, list2):
	zipped_pairs = zip(list2, list1)
	z = [x for (_, x) in sorted(zipped_pairs)]
	return z

def product(l):
	por = 1
	for i in range(len(l)):
		por *= l[i]
	return por

def binarySearchCount(arr, n, key):
	left = 0
	right = n - 1
	count = 0
	while left <= right:
		mid = int((right + left) / 2)
		if arr[mid] <= key:
			count = mid + 1
			left = mid + 1
		else:
			right = mid - 1
	return count

def countdig(n):
	c = 0
	while n > 0:
		n //= 10
		c += 1
	return c

def countGreater(arr, n, k):
	l = 0
	r = n - 1
	leftGreater = n
	while l <= r:
		m = int(l + (r - l) / 2)
		if arr[m] >= k:
			leftGreater = m
			r = m - 1
		else:
			l = m + 1
	return n - leftGreater
for ik in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			f = 1
			break
	if f == 0:
		print('NO')


import bisect as bi
import math as mt
import collections as cc
I = lambda : list(map(int, input().split()))
for tc in range(int(input())):
	(n,) = I()
	l = I()
	d = l.copy()
	d.sort(reverse=True)
	f = cc.defaultdict(list)
	for i in range(n):
		f[l[i]] = i
	tf = 0
	ans = []
	for cu in range(n):
		cur = f[d[cu]]
		i = cur - 1
		j = cur + 1
		tf = 0
		while i >= 0 and j < n:
			if l[i] < l[cur] and l[j] < l[cur]:
				tf = 1
				ans = [i + 1, cur + 1, j + 1]
				break
			i -= 1
			j += 1
		if tf:
			break
	if tf:
		print('YES')
		print(*ans)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	(i, j, k, f) = (0, 0, 0, 0)
	for x in range(1, n):
		if f == 0:
			if l[x] < l[i]:
				i = x
			else:
				j = x
				f = 1
		elif l[x] > l[j]:
			j = x
		else:
			k = x
			break
	if k == 0:
		print('NO')
	else:
		print('YES')
		print(i + 1, j + 1, k + 1)


import sys, bisect, string, math, time, functools, random, fractions
from heapq import heappush, heappop, heapify
from collections import deque, defaultdict, Counter
from itertools import permutations, combinations, groupby
rep = range

def Golf():
	(n, *t) = map(int, open(0).read().split())

def I():
	return int(input())

def S_():
	return input()

def IS():
	return input().split()

def LS():
	return [i for i in input().split()]

def MI():
	return map(int, input().split())

def LI():
	return [int(i) for i in input().split()]

def LI_():
	return [int(i) - 1 for i in input().split()]

def NI(n):
	return [int(input()) for i in range(n)]

def NI_(n):
	return [int(input()) - 1 for i in range(n)]

def StoLI():
	return [ord(i) - 97 for i in input()]

def ItoS(n):
	return chr(n + 97)

def LtoS(ls):
	return ''.join([chr(i + 97) for i in ls])

def RA():
	return map(int, open(0).read().split())

def GI(V, E, ls=None, Directed=False, index=1):
	org_inp = []
	g = [[] for i in R(V)]
	FromStdin = True if ls == None else False
	for i in R(E):
		if FromStdin:
			inp = LI()
			org_inp.append(inp)
		else:
			inp = ls[i]
		if len(inp) == 2:
			(a, b) = inp
			c = 1
		else:
			(a, b, c) = inp
		if index == 1:
			a -= 1
			b -= 1
		aa = (a, c)
		bb = (b, c)
		g[a].append(bb)
		if not Directed:
			g[b].append(aa)
	return (g, org_inp)

def GGI(h, w, search=None, replacement_of_found='.', mp_def={'#': 1, '.': 0}, boundary=1):
	mp = [boundary] * (w + 2)
	found = {}
	for i in R(h):
		s = input()
		for char in search:
			if char in s:
				found[char] = (i + 1) * (w + 2) + s.index(char) + 1
				mp_def[char] = mp_def[replacement_of_found]
		mp += [boundary] + [mp_def[j] for j in s] + [boundary]
	mp += [boundary] * (w + 2)
	return (h + 2, w + 2, mp, found)

def TI(n):
	return GI(n, n - 1)

def accum(ls):
	rt = [0]
	for i in ls:
		rt += [rt[-1] + i]
	return rt

def bit_combination(n, base=2):
	rt = []
	for tb in R(base ** n):
		s = [tb // base ** bt % base for bt in R(n)]
		rt += [s]
	return rt

def gcd(x, y):
	if y == 0:
		return x
	if x % y == 0:
		return y
	while x % y != 0:
		(x, y) = (y, x % y)
	return y

def YN(x):
	print(['NO', 'YES'][x])

def Yn(x):
	print(['No', 'Yes'][x])

def show(*inp, end='\n'):
	if show_flg:
		print(*inp, end=end)
mo = 10 ** 9 + 7
inf = float('inf')
FourNb = [(-1, 0), (1, 0), (0, 1), (0, -1)]
EightNb = [(-1, 0), (1, 0), (0, 1), (0, -1), (1, 1), (-1, -1), (1, -1), (-1, 1)]
compas = dict(zip('WENS', FourNb))
cursol = dict(zip('LRUD', FourNb))
l_alp = string.ascii_lowercase
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
input = lambda : sys.stdin.readline().rstrip()
show_flg = False
show_flg = True
for _ in range(I()):
	ans = None
	n = I()
	a = LI()
	b = a[::-1]
	l = [(0, a[0])]
	r = [(n - 1, b[0])]
	for i in rep(n - 1):
		(li, lm) = l[-1]
		(ri, rm) = r[-1]
		if a[i + 1] < lm:
			l += [(i + 1, a[i + 1])]
		else:
			l += [l[-1]]
		if b[i + 1] < rm:
			r += [(n - 1 - i - 1, b[i + 1])]
		else:
			r += [r[-1]]
	for i in rep(1, n - 1):
		(li, lm) = l[i - 1]
		(ri, rm) = r[n - i - 1]
		if lm < a[i] > rm:
			ans = (li + 1, i + 1, ri + 1)
			break
	if ans:
		YN(1)
		print(*ans)
	else:
		YN(0)


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	flag = True
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = False
			break
	if flag == True:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	d = {}
	flag = 1
	for i in range(n):
		d[a[i]] = i + 1
	b = a[0]
	for i in range(1, n - 1):
		if b < a[i]:
			for j in range(i + 1, n):
				if a[i] > a[j]:
					print('YES')
					print(d[b], d[a[i]], d[a[j]])
					flag = 0
					break
		if not flag:
			break
		b = min(b, a[i])
	if flag:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = [int(i) for i in input().strip().split()]
	found = False
	for i in range(1, n - 1):
		(indj, indk) = (-1, -1)
		for j in range(0, i):
			if a[j] < a[i]:
				indj = j
				break
		for k in range(i + 1, n):
			if a[k] < a[i]:
				indk = k
				break
		if indj != -1 and indk != -1:
			found = True
			print('YES')
			print(indj + 1, i + 1, indk + 1)
			break
	if not found:
		print('NO')


import sys
import heapq, functools, collections
import math, random
from collections import Counter, defaultdict

def solve(lst):
	console('----- solving ------')
	for (i, (a, b, c)) in enumerate(zip(lst, lst[1:], lst[2:])):
		if a < b and b > c:
			print('YES')
			print('{} {} {}'.format(i + 1, i + 2, i + 3))
			return
	print('NO')
	return

def console(*args):
	print('\x1b[36m', *args, '\x1b[0m', file=sys.stderr)
	return
for case_num in range(int(input())):
	k = int(input())
	lst = list(map(int, input().split()))
	res = solve(lst)


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	prev = 0
	curr = -1
	next = -1
	for i in range(1, n):
		if curr == -1:
			if a[i] > a[prev]:
				curr = i
			else:
				prev = i
		elif a[i] < a[curr]:
			next = i
			break
		else:
			curr = i
	if next == -1:
		print('NO')
	else:
		print('YES')
		print(prev + 1, curr + 1, next + 1)


def f(l, n):
	for i in range(1, n - 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			print('YES')
			return [i, i + 1, i + 2]
	return ['NO']
for a in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	print(*f(l, n))


from sys import stdin, stdout
cin = stdin.readline
cout = stdout.write
mp = lambda : list(map(int, cin().split()))
(t,) = mp()
for _ in range(t):
	(n,) = mp()
	a = mp()
	f1 = f2 = -1
	for i in range(1, n):
		if a[i] - a[i - 1] > 0:
			f1 = i
		elif a[i] - a[i - 1] < 0:
			f2 = i
		if f1 + 1 == f2:
			cout('YES\n')
			cout(str(f1) + ' ' + str(f1 + 1) + ' ' + str(f1 + 2) + '\n')
			break
	else:
		cout('NO\n')


import sys

def II():
	return int(sys.stdin.readline())

def LI():
	return list(map(int, sys.stdin.readline().split()))

def MI():
	return map(int, sys.stdin.readline().split())

def SI():
	return sys.stdin.readline().strip()
t = II()
for q in range(t):
	n = II()
	a = LI()
	boo = False
	for i in range(1, n - 1):
		l = i - 1
		r = i + 1
		b1 = False
		b2 = False
		while l > -1:
			if a[l] > a[i]:
				l -= 1
			else:
				b1 = True
				break
		while r < n:
			if a[r] > a[i]:
				r += 1
			else:
				b2 = True
				break
		if b1 and b2:
			boo = True
			ans = [l + 1, i + 1, r + 1]
			break
	if boo == True:
		print('YES')
		print(*ans)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	x = y = z = t = 0
	for i in range(n - 2):
		if l[i] < l[i + 1] and l[i + 2] < l[i + 1]:
			x = i + 1
			y = i + 2
			z = i + 3
			t = 1
			break
	if t == 1:
		print('YES')
		print(x, y, z)
	else:
		print('NO')


import sys
import math
import heapq
import collections

def inputnum():
	return int(input())

def inputnums():
	return map(int, input().split())

def inputlist():
	return list(map(int, input().split()))

def inputstring():
	return [x for x in input()]

def inputmatrixchar(rows):
	arr2d = [[j for j in input().strip()] for i in range(rows)]
	return arr2d

def inputmatrixint(rows):
	arr2d = []
	for _ in range(rows):
		arr2d.append([int(i) for i in input().split()])
	return arr2d
t = int(input())
for q in range(t):
	n = inputnum()
	a = inputlist()
	minleft = [0] * n
	minright = [0] * n
	minleftind = [0] * n
	minrightind = [0] * n
	cur = a[0]
	ind = 0
	for i in range(n):
		if cur > a[i]:
			ind = i
			cur = a[i]
		minright[i] = cur
		minrightind[i] = ind
	cur = a[n - 1]
	ind = n - 1
	for i in reversed(range(n)):
		if cur > a[i]:
			ind = i
			cur = a[i]
		minleft[i] = cur
		minleftind[i] = ind
	done = False
	for i in range(1, n - 1):
		if minright[i] < a[i] and minleft[i] < a[i]:
			done = True
			print('YES')
			print(minrightind[i] + 1, i + 1, minleftind[i] + 1)
			break
	if not done:
		print('NO')


t = int(input())
vec_indexs = []
vec_resposta = []
for k in range(t):
	n = int(input())
	vec = input().split()
	for i in range(n):
		vec[i] = int(vec[i])
	trobat = False
	i = 1
	while i < n - 1 and trobat is False:
		if vec[i - 1] < vec[i] and vec[i] > vec[i + 1]:
			maxx = vec[i]
			idx = vec.index(maxx)
			trobat = True
		i += 1
	if trobat == False:
		idx = 1
	i = 0
	t_e = False
	while t_e is False and i < idx and (trobat is True):
		if vec[i] < maxx:
			t_e = True
			idx_e = i
		i += 1
	t_d = False
	i = n - 1
	while t_d is False and i > idx and (trobat is True):
		if vec[i] < maxx:
			t_d = True
			idx_d = i
		i -= 1
	if t_d is True and t_e is True and (trobat is True):
		vec_indexs.append(str(idx_e + 1) + ' ' + str(idx + 1) + ' ' + str(idx_d + 1))
		vec_resposta.append('YES')
	else:
		vec_indexs.append(str(0))
		vec_resposta.append('NO')
for i in range(t):
	print(vec_resposta[i])
	if vec_resposta[i] == 'YES':
		print(vec_indexs[i])


def main_function():
	t = int(input())
	output_list = []
	for i in range(t):
		input()
		p = [int(i) for i in input().split(' ')]
		i = 0
		j = 1
		k = 2
		while k <= len(p):
			if k == len(p):
				output_list.append('NO')
				break
			if p[j] > p[i] and p[j] > p[k]:
				output_list.append(f'YES\n{i + 1} {j + 1} {k + 1}')
				break
			else:
				i += 1
				j += 1
				k += 1
	return '\n'.join(output_list)
print(main_function())


import sys
from collections import defaultdict as dd
from collections import deque
from fractions import Fraction as f
from copy import *
from bisect import *
from heapq import *
from math import *
from itertools import permutations

def eprint(*args):
	print(*args, file=sys.stderr)
zz = 1
if zz:
	input = sys.stdin.readline
else:
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('all.txt', 'w')

def li():
	return [int(x) for x in input().split()]

def fli():
	return [float(x) for x in input().split()]

def comp(a, b):
	if a > b:
		return 2
	return 2 if a == b else 0

def gi():
	return [x for x in input().split()]

def fi():
	return int(input())

def swap(a, i, j):
	(a[i], a[j]) = (a[j], a[i])

def si():
	return list(input().rstrip())

def mi():
	return map(int, input().split())

def gh():
	sys.stdout.flush()

def graph(n, m):
	for i in range(m):
		(x, y) = mi()
		a[x].append(y)
		a[y].append(x)

def bo(i):
	return ord(i) - ord('a')
t = fi()
while t > 0:
	t -= 1
	n = fi()
	a = li()
	flag = 0
	pre = [-1 for i in range(n)]
	minIndex = 0
	mini = 10 ** 18
	for i in range(n):
		if i > 0 and mini < a[i]:
			pre[i] = minIndex
		else:
			pre[i] = -1
		if mini > a[i]:
			mini = a[i]
			minIndex = i
	suf = [-1 for i in range(n)]
	minIndex = 0
	mini = 10 ** 18
	for i in range(n - 1, -1, -1):
		if i < n - 1 and mini < a[i]:
			suf[i] = minIndex
		else:
			suf[i] = -1
		if mini > a[i]:
			mini = a[i]
			minIndex = i
	for i in range(1, n - 1):
		if pre[i] != -1 and suf[i] != -1:
			print('YES')
			flag = 1
			print(pre[i] + 1, i + 1, suf[i] + 1)
			break
	if flag == 0:
		print('NO')


for i in range(int(input())):
	n = int(input())
	k = list(map(int, input().split()))
	l = []
	for i in range(n - 2):
		if k[i] < k[i + 1] and k[i + 1] > k[i + 2]:
			l.append(i)
			break
	if len(l) == 0:
		print('NO')
	else:
		print('YES')
		print(str(l[0] + 1) + ' ' + str(l[0] + 2) + ' ' + str(l[0] + 3))


for i in range(int(input())):
	n = int(input())
	b = n
	a = [int(i) for i in input().split()]
	c = 0
	d = 1
	go = True
	while b > 2:
		if a[c] != b and a[-d] != b:
			print('YES')
			go = False
			x = a.index(b)
			print(x, x + 1, x + 2)
			break
		elif a[c] == b:
			c += 1
		else:
			d += 1
		b -= 1
	if go:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	first = p[0]
	second = p[0]
	i = 0
	j = 0
	k = 0
	flag = 0
	for x in range(1, n):
		if p[x] < first and flag == 0:
			first = p[x]
			i = x
			continue
		elif flag == 0:
			j = x
			second = p[j]
			flag = 1
			continue
		if p[x] > second and flag == 1:
			second = p[x]
			j = x
			continue
		elif flag == 1:
			k = x
			third = p[k]
			flag = 2
			break
	if flag == 2:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


import sys

def inputt():
	return sys.stdin.readline().strip()

def printt(n):
	sys.stdout.write(str(n) + '\n')

def listt():
	return [int(i) for i in inputt().split()]
t = int(inputt())
for _ in range(t):
	n = int(inputt())
	l = listt()
	for j in range(1, n - 1):
		if l[j] > l[j - 1] and l[j] > l[j + 1]:
			printt('YES')
			print(j, j + 1, j + 2)
			break
		elif j == n - 2:
			printt('NO')


import sys
input = sys.stdin.readline
num_tests = int(input().strip())
data = [None] * num_tests
for i in range(num_tests):
	p = int(input().strip())
	digits_str = input().strip().split(' ')
	digits = [int(d) for d in digits_str]
	data[i] = (p, digits)
for (p, digits) in data:
	found_camel = False
	i = 0
	while i < p - 2:
		if digits[i] < digits[i + 1] and digits[i + 2] < digits[i + 1]:
			found_camel = True
			break
		i += 1
	if found_camel:
		print('YES')
		print(str(i + 1) + ' ' + str(i + 2) + ' ' + str(i + 3))
	else:
		print('NO')


t = int(input())
while t:
	n = int(input())
	a = input().split()
	a = list(map(int, a))
	m = [0 for i in range(n)]
	m[-1] = n - 1
	for i in range(n - 2, -1, -1):
		if a[i] < a[m[i + 1]]:
			m[i] = i
		else:
			m[i] = m[i + 1]
	(x, y, z) = (0, 0, 0)
	for i in range(n - 2):
		for j in range(i + 1, n - 1):
			if a[i] < a[j] and a[j] > a[m[j + 1]]:
				(x, y, z) = (i + 1, j + 1, m[j + 1] + 1)
			if x:
				break
		if x:
			break
	if x:
		print('YES')
		print(x, y, z)
	else:
		print('NO')
	t -= 1


for _ in range(int(input())):
	n = int(input())
	mass = list(map(int, input().split()))
	i = 0
	j = 1
	k = 2
	flag = 1
	for g in range(3, n + 1):
		if mass[i] < mass[j] and mass[k] < mass[j]:
			flag = 0
			print('YES')
			print(i + 1, j + 1, k + 1)
			break
		i += 1
		j += 1
		k += 1
	if flag:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	lis = list(map(int, input().split()))
	for i in range(n - 2):
		if lis[i] < lis[i + 1] > lis[i + 2]:
			print('Yes')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('No')


import math, sys
from collections import defaultdict, Counter, deque
INF = float('inf')
MOD = 1000000007

def gcd(a, b):
	while b:
		(a, b) = (b, a % b)
	return a

def isPrime(n):
	if n <= 1:
		return False
	i = 2
	while i ** 2 <= n:
		if n % i == 0:
			return False
		i += 1
	return True

def primeFactors(n):
	factors = []
	i = 2
	while i ** 2 <= n:
		while n % i == 0:
			factors.append(i)
			n //= i
		i += 1
	if n > 1:
		factors.append(n)
	return factors

def vars():
	return map(int, input().split())

def array():
	return list(map(int, input().split()))

def main():
	n = int(input())
	arr = array()
	(l, m, r) = (0, 1, 2)
	while r < n:
		if arr[l] < arr[m] > arr[r]:
			print('YES')
			print(l + 1, m + 1, r + 1)
			return
		l += 1
		m += 1
		r += 1
	print('NO')
t = int(input())
for _ in range(t):
	main()


T = int(input())
for t in range(T):
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(*[i, i + 1, i + 2])
			break
		elif i == n - 2:
			print('NO')


import sys
import math
from collections import defaultdict, Counter
t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	m = max(a)
	ind = a.index(m)
	if ind == n - 1 or ind == 0:
		for j in range(1, n - 1):
			if a[j] > a[j - 1] and a[j] > a[j + 1]:
				print('YES')
				print(j, j + 1, j + 2)
				break
		else:
			print('NO')
	else:
		print('YES')
		print(ind, ind + 1, ind + 2)


def solve(permu):
	if len(permu) < 3:
		return (-1, -1, -1)
	start = 0
	end = len(permu) - 1
	n = len(permu)
	while end - start > 1:
		if permu[start] == n:
			start += 1
			n -= 1
			continue
		if permu[end] == n:
			end -= 1
			n -= 1
			continue
		for i in range(start, end + 1):
			if permu[i] == n:
				return (i - 1, i, i + 1)
	return (-1, -1, -1)
T = int(input())
for _ in range(T):
	n = int(input())
	permu = list(map(int, input().split()))
	(i, j, k) = solve(permu)
	if i == -1:
		print('NO')
	else:
		print('YES')
		print(i + 1, j + 1, k + 1)


import sys, io, os, time
from collections import defaultdict
from collections import OrderedDict
from collections import deque
from itertools import combinations
from itertools import permutations
import bisect, math, heapq
alphabet = 'abcdefghijklmnopqrstuvwxyz'
input = sys.stdin.readline
for ii in range(int(input())):
	n = int(input())
	f = 0
	arr = list(map(int, input().split()))
	for i in range(n - 1):
		if arr[i] < arr[i + 1]:
			for j in range(i + 1, n):
				if arr[i + 1] > arr[j]:
					print('YES')
					print(i + 1, i + 2, j + 1)
					f = 1
				if f:
					break
		if f:
			break
	if not f:
		print('NO')


for i in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	a = False
	for i in range(n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			a = True
			break
	if a == False:
		print('NO')


for s in [*open(0)][2::2]:
	a = (*map(int, s.split()),)
	i = ''.join(('01'[x < y > z] for (x, y, z) in zip(a, a[1:], a[2:]))).find('1')
	print(*(['YES', i + 1, i + 2, i + 3], ['NO'])[i < 0])


import math

def main():
	t = int(input())
	for _ in range(t):
		print(case())

def case():
	n = int(input())
	p = list(map(int, input().split()))
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			return f'YES\n{i} {i + 1} {i + 2}'
	return 'NO'
main()


t = int(input())
for i in range(t):
	n = int(input())
	lst = [int(i) for i in input().split()]
	for i in range(1, n - 1):
		if lst[i] > lst[i - 1] and lst[i] > lst[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


def solve(n, a):
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
	return
test_cases = int(input())
for _ in range(test_cases):
	n = int(input())
	a = list(map(int, input().split()))
	solve(n, a)


tests = int(input())
while tests > 0:
	size = int(input())
	p = [int(x) for x in input().split()]
	for x in range(size - 2):
		if p[x] < p[x + 1] and p[x + 1] > p[x + 2]:
			print('YES')
			print(x + 1, ' ', x + 2, ' ', x + 3)
			break
	else:
		print('NO')
	tests = tests - 1


from sys import *
t = int(stdin.readline())
while t > 0:
	n = int(stdin.readline())
	arr = list(map(int, stdin.readline().split()))
	flag = 0
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')
	t -= 1


for test_case in range(int(input())):
	length = int(input())
	array = list(map(int, input().split()))
	ans = []
	for x in range(1, length - 1):
		for y in range(x, -1, -1):
			if array[y] < array[x]:
				ans.append(array[y])
				break
		else:
			continue
		for z in range(x + 1, length):
			if array[z] < array[x]:
				ans.append(array[x])
				ans.append(array[z])
				break
		if len(ans) == 3:
			break
		else:
			ans = []
	else:
		print('NO')
		continue
	print('YES')
	print(f'{array.index(ans[0]) + 1} {array.index(ans[1]) + 1} {array.index(ans[2]) + 1}')


import sys

def scan_permutation(perm_list):
	for k in range(len(perm_list) - 2):
		if perm_list[k] < perm_list[k + 1] and perm_list[k + 1] > perm_list[k + 2]:
			return [k + 1, k + 2, k + 3]
	return []
T = int(input())
for k in range(T):
	perm_len = int(input())
	perm_list = list(map(int, sys.stdin.readline().split()))
	indices = scan_permutation(perm_list)
	if len(indices) == 0:
		print('NO')
	else:
		print('YES')
		print(*indices, sep=' ')


for _ in range(int(input())):
	n = int(input())
	target = n
	arr = list(map(int, input().split()))
	i = 0
	k = n - 1
	while i <= k:
		if arr[i] != target and arr[k] != target:
			print('YES')
			print(i + 1, arr.index(target) + 1, k + 1)
			break
		elif arr[i] == target:
			i += 1
			target -= 1
		elif arr[k] == target:
			k -= 1
			target -= 1
	else:
		print('NO')


from os import path
import sys
from heapq import heappush, heappop
from functools import cmp_to_key as ctk
from collections import deque, defaultdict as dd
from bisect import bisect, bisect_left, bisect_right, insort, insort_left, insort_right
from itertools import permutations
from datetime import datetime
from math import ceil, sqrt, log, gcd

def ii():
	return int(input())

def si():
	return input()

def mi():
	return map(int, input().split())

def li():
	return list(mi())
abc = 'abcdefghijklmnopqrstuvwxyz'
mod = 1000000007
inf = float('inf')
vow = ['a', 'e', 'i', 'o', 'u']
(dx, dy) = ([-1, 1, 0, 0], [0, 0, 1, -1])

def bo(i):
	return ord(i) - ord('a')
file = 1

def solve():
	for _ in range(ii()):
		n = ii()
		a = li()
		f2 = 0
		for i in range(n):
			(f, f1) = (-1, -1)
			for j in range(i - 1, -1, -1):
				if a[i] > a[j]:
					f = j
					break
			for j in range(i + 1, n):
				if a[i] > a[j]:
					f1 = j
					break
			if f != -1 and f1 != -1:
				print('YES')
				print(f + 1, i + 1, f1 + 1)
				f2 = 1
				break
		if f2 == 0:
			print('NO')
if file:
	if path.exists('input1.txt'):
		sys.stdin = open('input1.txt', 'r')
		sys.stdout = open('output1.txt', 'w')
	else:
		input = sys.stdin.readline
solve()


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	l = 0
	r = n - 1
	val = n
	while val:
		if a[r] == val:
			r -= 1
		elif a[l] == val:
			l += 1
		else:
			break
		val -= 1
	if val == 0:
		print('NO')
		continue
	print('YES')
	ind = a.index(val)
	for i in range(ind):
		if a[i] < val:
			print(i + 1, end=' ')
			break
	print(ind + 1, end=' ')
	for i in range(ind + 1, n):
		if a[i] < val:
			print(i + 1, end=' ')
			break
	print()


for _ in range(int(input())):
	n = int(input())
	ar = list(map(int, input().split()))
	z = 0
	(l, s, d) = (0, 0, 0)
	for i in range(1, n - 1):
		if ar[i - 1] < ar[i] and ar[i] > ar[i + 1]:
			(l, s, d) = (i, i + 1, i + 2)
			z = 1
			break
	if z == 0:
		print('NO')
	else:
		print('YES')
		print(l, s, d)


input = __import__('sys').stdin.readline
for _ in range(int(input())):
	n = int(input())
	s = list(map(int, input().split()))
	f = 0
	l = r = 1
	while r + 1 < n:
		while r + 1 < n and s[r + 1] == s[r]:
			r += 1
		if r + 1 >= n:
			break
		if s[l - 1] < s[r] > s[r + 1]:
			print('YES')
			print(l, r + 1, r + 2)
			f = 1
			break
		r += 1
		l = r
	if f == 0:
		print('NO')


def solve():
	n = int(input())
	lis = [int(i) for i in input().split()]
	flag = True
	for i in range(len(lis) - 2):
		(a, b, c) = lis[i:i + 3]
		if a < b and b > c:
			print('YES')
			print(i + 1, i + 2, i + 3)
			return
	print('NO')
t = int(input())
for _ in range(t):
	solve()


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	mn = [l[0], 1]
	for i in range(1, n):
		if l[i] < mn[0]:
			mn = [l[i], i + 1]
		elif l[i] > mn[0]:
			for j in range(n - 1, i, -1):
				if l[j] < l[i]:
					print('YES')
					f = 1
					print(mn[1], i + 1, j + 1)
					break
		if f == 1:
			break
	if f == 0:
		print('NO')


import math
for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	dic = {}
	for i in range(n):
		dic[arr[i]] = i
	b = False
	ans = []
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] and arr[i] > arr[i + 1]:
			ans = [i, i + 1, i + 2]
			b = True
			break
	if b:
		print('YES')
		print(*ans)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	pick = 0
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] > arr[i + 1]:
			pick = i
			break
	if pick:
		print('YES')
		print(pick, pick + 1, pick + 2)
	else:
		print('NO')


t = int(input())
i = 0
while i < t:
	n = int(input())
	arr = list(map(int, input().split()))
	x = False
	res = []
	y = False
	for j in range(n - 1):
		if arr[j] < arr[j + 1]:
			x = True
		elif x == True:
			y = True
			res.append(j + 1)
			break
	if len(res) == 0:
		print('NO')
	else:
		print('YES')
		print(res[0] - 2 + 1, res[0] - 1 + 1, res[0] + 1)
	i = i + 1


for _ in range(int(input())):
	n = int(input())
	arr = [int(i) for i in input().split()]
	f = None
	for i in range(n - 2):
		if arr[i] < arr[i + 1] > arr[i + 2]:
			f = i
	if f is not None:
		print('YES')
		print(f + 1, f + 2, f + 3)
	else:
		print('NO')


def problemA():
	n = int(input())
	l = list(map(int, input().split()))
	i = 0
	while i < n - 1 and l[i] > l[i + 1]:
		i += 1
	if i == n - 1:
		print('NO')
		return
	j = i + 1
	while j < n - 1 and l[j] < l[j + 1]:
		j += 1
	if j == n - 1:
		print('NO')
		return
	print('YES')
	print(i + 1, j + 1, j + 2)
cases = int(input())
for _ in range(cases):
	problemA()


a = int(input())
for i in range(0, a):
	n = a = int(input(''))
	l = list(map(int, input().split()))
	f = False
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			f = True
			break
	if f:
		i += 1
		print('YES')
		print(i - 1, i, i + 1)
	else:
		print('NO')


import math, sys
from sys import stdin, stdout
from collections import Counter, defaultdict, deque
input = stdin.readline
I = lambda : int(input())
li = lambda : list(map(int, input().split()))

def solve():
	n = I()
	a = li()
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
for _ in range(I()):
	solve()


def solve(arr):
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	solve(arr)


from sys import stdin, setrecursionlimit, stdout
from collections import deque
from math import sqrt, floor, ceil, log, log2, log10, pi, gcd, sin, cos, asin
from heapq import heapify, heappop, heappush, heapreplace, heappushpop

def ii():
	return int(stdin.readline())

def fi():
	return float(stdin.readline())

def mi():
	return map(int, stdin.readline().split())

def fmi():
	return map(float, stdin.readline().split())

def li():
	return list(mi())

def si():
	return stdin.readline().rstrip()

def lsi():
	return list(si())
res = ['YES', 'NO']

def solve():
	n = ii()
	a = li()
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
	return
test_case = ii()
while test_case:
	test_case -= 1
	solve()


def solve(n):
	flag = True
	if a == sorted(a):
		return (-1, -1, -1)
	if a == sorted(a, reverse=True):
		return (-1, -1, -1)
	c = a.index(1)
	if a[:c + 1] == sorted(a[:c + 1], reverse=True) and a[c:] == sorted(a[c:], reverse=False):
		return (-1, -1, -1)
	for i in range(c - 1, 0, -1):
		if a[i] > a[i - 1]:
			return (i - 1, i, c)
	for i in range(c + 1, n):
		if a[i] < a[i - 1]:
			return (c, i - 1, i)
t = int(input())
cnt = 0
while cnt < t:
	cnt += 1
	n = int(input())
	a = [int(i) for i in input().split()]
	(t1, t2, t3) = solve(n)
	if t1 == -1:
		print('NO')
	else:
		print('YES')
		print(t1 + 1, t2 + 1, t3 + 1)


T = int(input())
for _ in range(T):
	n = int(input())
	arr = list(map(int, input().split()))
	f = 0
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			f = 1
			first = i
			second = i + 1
			third = i + 2
			break
	if f > 0:
		print('YES')
		print(first, second, third)
	else:
		print('NO')


a = int(input(''))
for numbers in range(0, a):
	b = int(input(''))
	numbers = list(map(int, input().split()))
	for i in range(1, b - 1):
		if numbers[i] > numbers[i + 1] and numbers[i] > numbers[i - 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


def find(P):
	temp = max(P) + 1
	MIN = [temp] * len(P)
	for i in range(1, len(P) + 1):
		temp = min(temp, P[-i])
		MIN[-i] = temp
	for i in range(len(P) - 2):
		if P[i] < P[i + 1] and P[i + 1] > MIN[i + 2]:
			for j in range(i + 2, len(P)):
				if P[j] == MIN[i + 2]:
					return (i + 1, i + 2, j + 1)
	return (-1, -1, -1)
for _ in range(int(input())):
	input()
	P = list(map(int, input().strip().split()))
	(a, b, c) = find(P)
	if a == -1:
		print('NO')
	else:
		print('YES')
		print(a, b, c)


for testcases in range(1, int(input()) + 1):
	n = int(input())
	ar = list(map(int, input().split()))
	(a, b, c) = (0, 0, 0)
	for i in range(n):
		(k, l) = (-1, -1)
		j = 0
		while j < i:
			if ar[i] > ar[j]:
				k = j
			j += 1
		j = i + 1
		while j < n:
			if ar[i] > ar[j]:
				l = j
			j += 1
		if k != -1 and l != -1:
			(a, b, c) = (k, i, l)
	if a == b and b == c and (c == 0):
		print('NO')
	else:
		print('YES')
		print(a + 1, b + 1, c + 1)


for i in range(int(input())):
	n = int(input())
	p = [int(num) for num in input().split()]
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


t = int(input())
for q in range(t):
	n = int(input())
	li = list(map(int, input().split(' ', n)[:n]))
	fl = 0
	for i in range(1, n - 1):
		if li[i] > li[i - 1] and li[i] > li[i + 1]:
			print('YES')
			fl = 1
			print(i, i + 1, i + 2)
			break
	if fl == 1:
		continue
	else:
		print('NO')


def triplet(arr):
	blanck = []
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			return str(i) + ' ' + str(i + 1) + ' ' + str(i + 2)
	return 'NO'
t = int(input())
for t_itr in range(t):
	arr_count = int(input())
	arr = list(map(int, input().rstrip().split()))
	result = triplet(arr)
	print(result)


for _ in range(int(input())):
	n = int(input())
	p = [int(x) for x in input().split()]
	ml = []
	mr = []
	m = n
	for x in p:
		m = min(m, x)
		ml.append(m)
	m = n
	for x in p[::-1]:
		m = min(m, x)
		mr.append(m)
	mr = mr[::-1]
	(a, b, c) = [-1, -1, -1]
	for i in range(1, n - 1):
		if ml[i - 1] < p[i] and p[i] > mr[i + 1]:
			a = p.index(ml[i - 1])
			b = i
			c = p.index(mr[i + 1])
	if [a, b, c] == [-1, -1, -1]:
		print('NO')
	else:
		print('YES')
		print(str(a + 1) + ' ' + str(b + 1) + ' ' + str(c + 1))


T = int(input())
for _ in range(T):
	n = int(input())
	l = list(map(int, input().split()))
	for i in range(n - 1):
		if l[i] < l[i + 1]:
			break
	k = -1
	for j in range(i + 1, n - 1):
		if l[j] > l[j + 1]:
			k = j + 1
			break
	if k != -1:
		print('YES')
		print(i + 1, 1 + j, k + 1)
	else:
		print('NO')


T = int(input())
for i in range(T):
	n = int(input())
	arr = [int(i) for i in input().split(' ')]
	left_mark = [False] * n
	right_mark = left_mark.copy()
	min_ = n + 2
	for (j, i) in enumerate(arr):
		if i < min_:
			min_ = i
		else:
			left_mark[j] = True
	min_ = n + 2
	for (j, i) in enumerate(arr[::-1]):
		if i < min_:
			min_ = i
		else:
			right_mark[n - 1 - j] = True
	for (j, i) in enumerate(right_mark):
		if right_mark[j] and left_mark[j]:
			print('Yes')
			for (k, i) in enumerate(arr[:j]):
				if i < arr[j]:
					print(k + 1, end=' ')
					break
			print(j + 1, end=' ')
			for (k, i) in enumerate(arr[j + 1:]):
				if i < arr[j]:
					print(k + j + 2)
					break
			break
	else:
		print('No')


from collections import Counter
tests = int(input())
for _ in range(tests):
	(n,) = map(int, input().split())
	arr = [int(a) for a in input().strip().split(' ')]
	inc = True if arr[0] < arr[1] else False
	if inc:
		for i in range(2, n):
			if arr[i] < arr[i - 1]:
				print('YES')
				print(i - 1, i, i + 1)
				inc = False
				break
		if inc:
			print('NO')
	else:
		found = False
		for i in range(2, n):
			if inc and arr[i] < arr[i - 1]:
				found = True
				print('YES')
				print(i - 1, i, i + 1)
				inc = False
				break
			if arr[i] > arr[i - 1]:
				inc = True
		if not found:
			print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	s = a[:]
	l = a[:]
	ans = []
	for i in range(1, n):
		s[i] = min(a[i], s[i - 1])
	for j in range(n - 2, -1, -1):
		l[j] = min(a[j], l[j + 1])
	for i in range(1, n - 1):
		if a[i] > s[i] and a[i] > l[i]:
			ans = [s[i], a[i], l[i]]
			break
	if ans:
		i = 0
		print('YES')
		for j in range(n):
			if ans[i] == a[j]:
				print(j + 1, end=' ')
				i += 1
				if i >= len(ans):
					break
		print('')
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	helper = []
	List = [int(x) for x in input().split()]
	a = 0
	b = 1
	c = 2
	for j in range(3, len(List) + 1):
		if List[b] > List[a] and List[b] > List[c]:
			helper.append(a + 1)
			helper.append(b + 1)
			helper.append(c + 1)
		if j == len(List) or len(helper):
			break
		a = b
		b = c
		c = j
	if len(helper):
		print('YES')
		print(*helper)
	else:
		print('NO')


def sol(lis):
	for i in range(1, len(lis) - 1):
		if lis[i] > lis[i - 1] and lis[i] > lis[i + 1]:
			return [i - 1, i, i + 1]
	return False
k = int(input())
for i in range(k):
	input()
	lis = list(map(int, input().split(' ')))
	lis = sol(lis)
	if lis:
		print('YES')
		for j in lis:
			print(j + 1, end=' ')
		print()
		continue
	print('NO')


test = int(input())
for t in range(test):
	n = int(input())
	lst = list(map(int, input().split()))
	Check = False
	for x in range(n):
		if x + 2 < n:
			if lst[x] < lst[x + 1] and lst[x + 1] > lst[x + 2]:
				Check = True
				print('YES')
				print(x + 1, x + 2, x + 3)
				break
	if Check == False:
		print('NO')


q = int(input())

def do():
	n = int(input())
	dat = list(map(int, input().split()))
	indx = None
	indy = None
	res = []
	for i in range(1, n):
		if dat[i - 1] < dat[i] and indx == None:
			indx = i
		if dat[i - 1] > dat[i]:
			indy = i
	if indx == None or indy == None or indx > indy:
		print('NO')
		return
	res.append(indx - 1 + 1)
	if dat[indx] > dat[indy]:
		res.append(indx + 1)
	else:
		res.append(indy - 1 + 1)
	res.append(indy + 1)
	print('YES')
	print(' '.join(list(map(str, res))))
for _ in range(q):
	do()


t = int(input())
for i in range(t):
	n = int(input())
	pi = list(map(int, input().split()))
	maxari = [n] * n
	maxarn = [pi[n - 1]] * n
	minari = [1] * n
	minarn = [pi[0]] * n
	for i in range(1, n):
		if pi[i] < minarn[i - 1]:
			minarn[i] = pi[i]
			minari[i] = i + 1
		else:
			minarn[i] = minarn[i - 1]
			minari[i] = minari[i - 1]
		if pi[n - i - 1] < maxarn[n - i]:
			maxarn[n - i - 1] = pi[n - i - 1]
			maxari[n - i - 1] = n - i
		else:
			maxarn[n - i - 1] = maxarn[n - i]
			maxari[n - i - 1] = maxari[n - i]
	ans = 0
	for i in range(1, n - 1):
		if pi[i] != maxarn[i] and pi[i] != minarn[i]:
			ans = 1
			print('YES')
			print(minari[i], i + 1, maxari[i])
			break
	if ans == 0:
		print('NO')


from bisect import bisect_left as lower_bound, bisect_right as upper_bound
from sys import stdin, stdout
from collections import defaultdict

def solve(arr, n):
	pass

def main():
	t = int(input())
	for _ in range(t):
		n = int(input())
		arr = list(map(int, input().strip().split()))
		st = [0]
		for i in range(1, n - 1):
			if arr[i] < arr[st[-1]]:
				st.append(i)
			else:
				st.append(st[-1])
		st1 = [n - 1]
		f = False
		(a, b, c) = (-1, -1, -1)
		for i in range(n - 2, 0, -1):
			st.pop()
			a = st[-1]
			b = i
			c = st1[-1]
			if arr[b] > arr[a] and arr[b] > arr[c]:
				f = True
				break
			if arr[b] < arr[st1[-1]]:
				st1.append(i)
			else:
				st1.append(st1[-1])
		if f:
			print('YES')
			print(a + 1, b + 1, c + 1)
		else:
			print('NO')
main()


for _ in range(int(input())):
	a = int(input())
	li = list(map(int, input().split()))
	for i in range(1, len(li) - 1):
		if li[i] > li[i - 1] and li[i] > li[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


def read_int():
	return int(input().strip())

def read_ints():
	return list(map(int, input().strip().split(' ')))

def solve():
	n = read_int()
	p = read_ints()
	for j in range(1, n - 1):
		if p[j - 1] < p[j] > p[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			return
	print('NO')
T = read_int()
for _ in range(T):
	solve()


n = int(input())
for i in range(0, n):
	l = int(input())
	y = list(map(int, input().split()))
	for j in range(l):
		temp1 = -1
		temp2 = -1
		for x in range(j):
			if y[x] < y[j]:
				temp1 = x
		for z in range(j, l):
			if y[z] < y[j]:
				temp2 = z
		if temp1 != -1 and temp2 != -1:
			print('YES')
			print(temp1 + 1, j + 1, temp2 + 1)
			flag = True
			break
		elif j == l - 1:
			print('NO')


t = int(input())
while t > 0:
	n = int(input())
	arr = [int(x) for x in input().split()]
	flag = False
	i = 0
	while i < n - 2:
		if arr[i] < arr[i + 1]:
			if arr[i + 1] > arr[i + 2]:
				flag = True
				break
		i += 1
	if flag:
		print('YES')
		print(str(i + 1) + ' ' + str(i + 2) + ' ' + str(i + 3))
	else:
		print('NO')
	t -= 1


from sys import stdin
import math
inp = lambda : stdin.readline().strip()
t = int(inp())
for _ in range(t):
	n = int(inp())
	p = [int(x) for x in inp().split()]
	mini = p[0]
	mindex = 1
	flag = False
	for i in range(n):
		if i > 0 and p[i] > mini:
			for j in range(i, n):
				if p[j] < p[i]:
					print('YES')
					print(mindex, end=' ')
					print(i + 1, end=' ')
					print(j + 1)
					flag = True
					break
			if flag:
				break
		else:
			mini = p[i]
			mindex = i + 1
	if not flag:
		print('NO')


for p in range(int(input())):
	(n, a) = (int(input()), -1)
	l = list(map(int, input().split(' ')))
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			a = i
			break
	if a != -1:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


import sys
t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, sys.stdin.readline().strip().split()))
	x1 = []
	x2 = []
	x = a[0]
	mni = 0
	for j in range(n):
		if a[j] < x:
			x = a[j]
			mni = j
		x1.append([x, mni])
	x = a[n - 1]
	mni = n - 1
	for j in range(n - 1, -1, -1):
		if a[j] < x:
			x = a[j]
			mni = j
		x2.append([x, mni])
	f = 0
	for j in range(1, n - 1):
		if x1[j - 1][0] < a[j] and a[j] > x2[n - j - 1][0]:
			print('YES')
			print(x1[j - 1][1] + 1, j + 1, x2[n - j - 1][1] + 1)
			f = 1
			break
	if f:
		continue
	print('NO')


T = int(input())
for t in range(T):
	n = int(input())
	p = [int(x) for x in input().split(' ')]
	found = True
	(i, j, k) = (0, 1, 2)
	while not (p[i] < p[j] and p[j] > p[k]):
		i += 1
		j += 1
		k += 1
		if k == len(p):
			found = False
			break
	if found:
		print(f'YES\n{i + 1} {j + 1} {k + 1}')
	else:
		print('NO')


for testcase in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	ans = -1
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			ans = i
			break
	if ans == -1:
		print('NO')
		continue
	print('YES')
	print(i + 1, i + 2, i + 3)


t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	i = 1
	(a, b, c) = (-1, -1, -1)
	found = False
	while i < n - 1:
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			a = i + 1
			b = i
			c = i + 2
			found = True
			break
		i += 1
	if found:
		print('YES')
		print(b, a, c)
	else:
		print('NO')


def go(arr):
	for i in range(len(arr) - 2):
		if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
			return i
	return -1
t = int(input())
for x in range(t):
	n = int(input())
	arr = list(map(int, input().split(' ')))
	key = go(arr)
	if key == -1:
		print('NO')
	else:
		print('YES')
		for i in range(3):
			print(i + key + 1, end=' ')
		print()


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	a = sorted(arr, reverse=True)
	mid = -1
	for i in range(n):
		(left, right) = (-1, -1)
		for j in range(n):
			if j < i and arr[i] > arr[j]:
				left = j
			if j > i and arr[i] > arr[j]:
				right = j
		if left != -1 and right != -1:
			mid = i
			break
	if -1 in [mid, left, right]:
		print('NO')
	else:
		print('YES')
		print(left + 1, mid + 1, right + 1)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().rstrip().rsplit()))
	flag = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(y) for y in input().split()]
	f = 0
	for j in range(n - 2):
		if a[j] < a[j + 1] and a[j + 1] > a[j + 2]:
			print('YES')
			print(j + 1, j + 2, j + 3)
			f = 1
			break
	if f == 0:
		print('NO')


for _ in range(int(input())):
	lens = int(input())
	arrs = [int(x) for x in input().split()]
	cnts = 0
	has = False
	for i in range(1, lens - 1):
		(a, b, c) = (arrs[i - 1], arrs[i], arrs[i + 1])
		if arrs[i - 1] < arrs[i] and arrs[i + 1] < arrs[i]:
			has = True
			ans = [i, i + 1, i + 2]
			break
	if has:
		print('YES')
		print(*ans)
	else:
		print('NO')


def solve(perm, l):
	for i in range(l - 2):
		if perm[i] < perm[i + 1] > perm[i + 2]:
			print('YES', i + 1, i + 2, i + 3)
			return 0
	print('NO')
t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(i) for i in input().split()]
	solve(a, n)


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	l = sorted(a)
	(i, k) = (0, n - 1)
	f = 1
	while i < k:
		x = l.pop()
		j = a.index(x)
		if i < j < k:
			print('YES')
			f = 0
			print(i + 1, j + 1, k + 1)
			break
		if i == j:
			i += 1
		elif k == j:
			k -= 1
	if f:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	A = [int(_) for _ in input().split()]
	for _ in range(n - 2):
		if A[_] < A[_ + 1] > A[_ + 2]:
			print('YES')
			print(_ + 1, _ + 2, _ + 3)
			break
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	l = list(map(int, input().strip().split()))
	l1 = l
	flag = 0
	if l1 == sorted(l1):
		print('NO')
	else:
		for i in range(1, n - 1):
			if l1[i] > l1[i - 1] and l1[i] > l1[i + 1]:
				print('YES')
				flag = 1
				print(str(i) + ' ' + str(i + 1) + ' ' + str(i + 2))
				break
		if flag == 0:
			print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	for i in range(n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


t = int(input())
while t != 0:
	n = int(input())
	arr = [int(x) for x in input().split()]
	c = 0
	for i in range(1, len(arr) - 1, 1):
		if arr[i - 1] < arr[i] & arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			c = 1
			break
	if c == 0:
		print('NO')
	t = t - 1


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	ok = False
	for i in range(n - 2):
		if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			ok = True
			break
	if not ok:
		print('NO')


from sys import stdin
TT = int(stdin.readline())
for loop in range(TT):
	n = int(stdin.readline())
	p = list(map(int, stdin.readline().split()))
	inds = [None] * n
	for i in range(n):
		inds[p[i] - 1] = i
	nmin = float('inf')
	nmax = float('-inf')
	for j in range(n):
		if inds[j] > nmin and inds[j] < nmax:
			print('YES')
			print(nmin + 1, inds[j] + 1, nmax + 1)
			break
		nmin = min(nmin, inds[j])
		nmax = max(nmax, inds[j])
	else:
		print('NO')


import sys
input = sys.stdin.readline
(inp, ip) = (lambda : int(input()), lambda : [int(w) for w in input().split()])
for _ in range(inp()):
	n = inp()
	x = ip()
	left = [0] * n
	right = [0] * n
	left[0] = right[0] = x[0]
	right[-1] = left[-1] = x[-1]
	for i in range(1, n - 1):
		j = n - i - 1
		left[i] = min(left[i - 1], x[i])
		right[j] = min(right[j + 1], x[j])
	flag = 0
	for i in range(1, n - 1):
		if left[i - 1] < x[i] > right[i + 1]:
			flag = 1
			break
	if flag:
		print('YES')
		print(x.index(left[i - 1]) + 1, i + 1, x.index(right[i + 1]) + 1)
	else:
		print('NO')


t = int(input())
for q in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	min = arr[0]
	minindex = 0
	midindex = -1
	maxindex = -1
	for i in range(n):
		if arr[i] < min:
			min = arr[i]
			minindex = i
		elif arr[i] > min:
			midindex = i
			break
	max = arr[midindex]
	if midindex != -1:
		for i in range(midindex, n):
			if arr[i] > max:
				max = arr[i]
				midindex = i
			elif arr[i] < max:
				maxindex = i
				break
		if minindex == -1 or midindex == -1 or maxindex == -1:
			print('NO')
		else:
			print('YES')
			print(minindex + 1, midindex + 1, maxindex + 1)
	else:
		print('NO')


def solution(x):
	offset = 0
	j = x.index(max(x))
	i = j - 1
	k = j + 1
	while k >= len(x) or i < 0:
		x.pop(j)
		if len(x) < 3:
			return 'No'
		offset += 1 if i < 0 else 0
		j = x.index(max(x))
		i = j - 1
		k = j + 1
	j += offset
	i = j - 1
	k = j + 1
	res = f'Yes\n{i + 1} {j + 1} {k + 1}'
	return res

def main():
	for test in range(int(input())):
		_ = input()
		p = list(map(int, input().split()))
		result = solution(p)
		print(result)
main()


for _ in range(int(input())):
	a = int(input())
	l = list(map(int, input().split()))
	flag = 0
	for i in range(1, a - 1):
		if l[i - 1] < l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	count = 1
	ar = list(map(int, input().split()))
	for i in range(n - 2):
		if ar[i] < ar[i + 1]:
			if ar[i + 2] < ar[i + 1]:
				print('YES')
				print(i + 1, i + 2, i + 3)
				count = 0
				break
	if count == 1:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	P = list(map(int, input().split()))
	for j in range(1, n - 1):
		x = P[j]
		for i in range(j):
			if P[i] < x:
				break
		else:
			continue
		for k in range(j + 1, n):
			if P[k] < x:
				break
		else:
			continue
		print('YES')
		print(i + 1, j + 1, k + 1)
		break
	else:
		print('NO')


from itertools import combinations
t = int(input())
a = []
for p in range(t):
	c = 0
	n = int(input())
	a = str(input()).split()
	for x in range(n):
		a[x] = int(a[x])
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			c = 1
			break
	if c == 0:
		print('NO')


t = int(input())
for _ in range(t):
	length = int(input())
	nums = list(map(int, input().split()))
	found = False
	for i in range(1, length - 1):
		if nums[i] > nums[i + 1] and nums[i] > nums[i - 1]:
			print('YES')
			print(f'{i} {i + 1} {i + 2}')
			found = True
			break
	if not found:
		print('NO')


t = int(input())
for case in range(t):
	n = int(input())
	p = [int(s) for s in input().split(' ')]
	ans = False
	f = 0
	while n > 0:
		i = p.index(n)
		if i in [0, n - 1]:
			n -= 1
			del p[i]
			if i == 0:
				f += 1
		else:
			ans = True
			indices = [f + i, f + i + 1, f + i + 2]
			break
	if ans:
		print('YES')
		print(*indices)
	else:
		print('NO')


from sys import stdin

def iinput():
	return int(stdin.readline())

def minput():
	return map(int, stdin.readline().split())

def linput():
	return list(map(int, stdin.readline().split()))
t = iinput()
while t:
	t -= 1
	n = iinput()
	a = linput()
	res = 'NO'
	for j in range(1, n - 1):
		if a[j - 1] < a[j] > a[j + 1]:
			res = 'YES'
			print(res)
			print(j, j + 1, j + 2)
			break
	if res == 'NO':
		print(res)


def helper(n, arr):
	if len(arr) <= 2:
		print('NO')
		return
	l = 0
	maxx = n + 1
	while len(arr) > 2:
		maxi = maxx - 1
		index = None
		index = arr.index(maxi)
		index += 1
		if arr[0] == maxi:
			arr = arr[1:]
			l += 1
			maxx = maxx - 1
			continue
		elif arr[len(arr) - 1] == maxi:
			arr = arr[0:len(arr) - 1]
			maxx = maxx - 1
			continue
		else:
			j = index + l
			i = index - 1 + l
			k = index + 1 + l
			print('YES')
			print(i, j, k)
			return
	print('NO')
	return
for _ in range(int(input())):
	n = int(input())
	arr = [int(x) for x in input().split()]
	helper(n, arr)


tests = int(input())
for i in range(tests):
	n = int(input())
	p = [int(x) for x in input().split()]
	found = 'NO'
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			found = 'YES'
			print('YES')
			print(i, i + 1, i + 2)
			break
	if found == 'NO':
		print('NO')


for i in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	b = []
	for i in a:
		b.append(i)
	while a != [] and (a.index(max(a)) == len(a) - 1 or a.index(max(a)) == 0):
		del a[a.index(max(a))]
	if a == []:
		print('NO')
	else:
		print('YES')
		print(b.index(max(a)), b.index(max(a)) + 1, b.index(max(a)) + 2)


def f(L):
	n = len(L)
	for i in range(1, n - 1):
		if L[i - 1] < L[i] and L[i] > L[i + 1]:
			M = [i, i + 1, i + 2]
			return M
	return [-1]
t = int(input())
for i in range(0, t):
	n = int(input())
	L = list(map(int, input().split()))
	if len(f(L)) == 1:
		print('NO')
	else:
		print('YES')
		print(*f(L))


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	output = False
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			output = True
			print('YES')
			print(i, i + 1, i + 2)
			break
	if output == False:
		print('NO')


import sys
input = sys.stdin.readline

def ceil(x):
	if x != int(x):
		x = int(x) + 1
	return x

def swaparr(arr, a, b):
	temp = arr[a]
	arr[a] = arr[b]
	arr[b] = temp

def gcd(a, b):
	if b == 0:
		return a
	return gcd(b, a % b)

def nCr(n, k):
	if k > n - k:
		k = n - k
	res = 1
	for i in range(k):
		res = res * (n - i)
		res = res / (i + 1)
	return int(res)

def upper_bound(a, x, lo=0, hi=None):
	if hi == None:
		hi = len(a)
	while lo < hi:
		mid = (lo + hi) // 2
		if a[mid] < x:
			lo = mid + 1
		else:
			hi = mid
	return lo

def primefs(n):
	primes = {}
	while n % 2 == 0 and n > 0:
		primes[2] = primes.get(2, 0) + 1
		n = n // 2
	for i in range(3, int(n ** 0.5) + 2, 2):
		while n % i == 0 and n > 0:
			primes[i] = primes.get(i, 0) + 1
			n = n // i
	if n > 2:
		primes[n] = primes.get(n, 0) + 1
	return primes

def power(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def swap(a, b):
	temp = a
	a = b
	b = temp
	return (a, b)

def find(x, link):
	p = x
	while p != link[p]:
		p = link[p]
	while x != p:
		nex = link[x]
		link[x] = p
		x = nex
	return p

def union(x, y, link, size):
	x = find(x, link)
	y = find(y, link)
	if size[x] < size[y]:
		(x, y) = swap(x, y)
	if x != y:
		size[x] += size[y]
		link[y] = x

def sieve(n):
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	return prime
MAXN = int(100000.0 + 5)

def spf_sieve():
	spf[1] = 1
	for i in range(2, MAXN):
		spf[i] = i
	for i in range(4, MAXN, 2):
		spf[i] = 2
	for i in range(3, ceil(MAXN ** 0.5), 2):
		if spf[i] == i:
			for j in range(i * i, MAXN, i):
				if spf[j] == j:
					spf[j] = i

def factoriazation(x):
	ret = {}
	while x != 1:
		ret[spf[x]] = ret.get(spf[x], 0) + 1
		x = x // spf[x]
	return ret

def int_array():
	return list(map(int, input().strip().split()))

def str_array():
	return input().strip().split()
MOD = int(1000000000.0) + 7
CMOD = 998244353
INF = float('inf')
NINF = -float('inf')
for _ in range(int(input())):
	n = int(input())
	a = int_array()
	f = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			f = 1
			print(i, i + 1, i + 2)
			break
	if not f:
		print('NO')


def main():
	t = int(input())
	while t > 0:
		n = int(input())
		a = input()
		ar = list(a.split())
		arr = list(map(int, ar))
		i = 1
		st = 0
		while i < n - 1:
			if arr[i] > arr[i + 1] and arr[i] > arr[i - 1]:
				print('YES')
				print(i, i + 1, i + 2)
				st = 1
				break
			i += 1
		if st == 0:
			print('NO')
		t -= 1
main()


for _ in range(int(input())):
	n = int(input())
	a = [int(x) for x in input().split()]
	t = 0
	for i in range(1, n - 1):
		if a[i] > max(a[i - 1], a[i + 1]):
			print('YES')
			print(i, i + 1, i + 2)
			t = 1
			break
	if t == 0:
		print('NO')


def solve(A):
	n = len(A)
	stack = []
	stack.append(0)
	for i in range(1, n):
		if A[i] < A[stack[-1]]:
			if len(stack) == 2:
				stack.append(i)
				break
			else:
				stack.pop()
				stack.append(i)
		elif len(stack) == 1:
			stack.append(i)
		elif len(stack) == 2:
			stack.pop()
			stack.append(i)
	if len(stack) != 3:
		print('NO')
	else:
		print('YES')
		for i in stack:
			print(i + 1, ' ', end='')
	return
T = int(input())
for i in range(T):
	N = int(input())
	A = [int(i) for i in input().split()][:N]
	solve(A)


import sys
q = int(input())
for i in range(q):
	n = int(sys.stdin.readline())
	a = [int(j) for j in sys.stdin.readline().split()]
	tekmin = 0
	tekmax = 0
	step = 0
	in1 = 0
	in2 = 0
	in3 = 0
	for i in range(1, n):
		if step == 0:
			if a[i - 1] < a[i]:
				step = 1
				in1 = i - 1
		if step == 1:
			if a[i - 1] > a[i]:
				in2 = i - 1
				in3 = i
				break
	if in3 == 0:
		print('NO')
	else:
		print('YES')
		print(in1 + 1, in2 + 1, in3 + 1)


import sys
inputlist = sys.stdin.readlines()
number_of_testcases = int(inputlist[0].strip())
i = 0
while i < 2 * number_of_testcases:
	i += 1
	n = int(inputlist[i].strip())
	i += 1
	numbers_list = list(map(int, inputlist[i].strip().split(' ')))
	min1 = numbers_list[0]
	min1_index = 0
	max_now = -1
	max_index = -1
	for j in range(1, n):
		if numbers_list[j] > min1:
			max_now = numbers_list[j]
			max_index = j
			break
		else:
			min1 = numbers_list[j]
			min1_index = j
	else:
		print('NO')
		continue
	for k in range(j + 1, n):
		if numbers_list[k] < max_now:
			min2_index = k
			print('YES')
			print(min1_index + 1, max_index + 1, min2_index + 1)
			break
		else:
			max_now = numbers_list[k]
			max_index = k
	else:
		print('NO')


import sys
input = sys.stdin.readline
MOD = 1000000007
MOD2 = 998244353
ii = lambda : int(input().strip('\n'))
si = lambda : input().strip('\n')
dgl = lambda : list(map(int, input().strip('\n')))
f = lambda : map(int, input().strip('\n').split())
il = lambda : list(map(int, input().strip('\n').split()))
ls = lambda : list(input().strip('\n'))
lsc = lambda : list(input().strip('\n').split(' '))
lsi = lambda : [int(i) for i in ls()]
let = 'abcdefghijklmnopqrstuvwxyz'
for _ in range(ii()):
	n = ii()
	l = il()
	mx1 = [l[0]]
	mx2 = [0] * n
	mx2[-1] = l[-1]
	ans = [-1, -1, -1]
	for i in range(1, n):
		mx1.append(min(mx1[i - 1], l[i]))
	for i in range(n - 2, -1, -1):
		mx2[i] = min(mx2[i + 1], l[i])
	for i in range(1, n - 1):
		if mx1[i - 1] < l[i] > mx2[i + 1]:
			ans[0] = l.index(mx1[i - 1]) + 1
			ans[1] = i + 1
			ans[2] = l.index(mx2[i + 1]) + 1
			break
	if sum(ans) > -3:
		print('YES')
		print(*ans)
	else:
		print('NO')


from math import *
t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


n = int(input())
for i in range(n):
	left = 1001
	mid = 0
	right = 1001
	li = 0
	mi = 0
	ri = 0
	cc = True
	t = int(input())
	arr = list(map(int, input().split(' ')))
	for s in range(len(arr)):
		if arr[s] < mid and left < mid:
			ri = s
			print('YES')
			print(li + 1, mi + 1, ri + 1)
			cc = False
			break
		if arr[s] < left:
			left = arr[s]
			li = s
		elif arr[s] > left and arr[s] > mid:
			mid = arr[s]
			mi = s
	if cc:
		print('NO')


import sys
input = sys.stdin.buffer.readline
import os
from math import *
t = int(input())
while t:
	t -= 1
	n = int(input())
	arr = list(map(int, input().split()))
	dif = []
	for i in range(n - 1):
		dif.append(arr[i] - arr[i + 1])
	check = False
	for i in range(n - 2):
		if dif[i] < 0 and dif[i + 1] > 0:
			check = True
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	if check == False:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	f = False
	for i in range(1, n - 1):
		a = [False, False]
		p1 = -1
		p2 = -1
		for j in range(i):
			if p[j] < p[i]:
				a[0] = True
				p1 = j
				break
		for j in range(i + 1, n):
			if p[i] > p[j]:
				a[1] = True
				p2 = j
				break
		if a[0] == True and a[1] == True:
			print('YES')
			print(p1 + 1, i + 1, p2 + 1)
			f = True
			break
	if not f:
		print('NO')


import sys
input = sys.stdin.readline
from collections import *
for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	m = 10 ** 18
	idx = -1
	l = []
	for i in range(n):
		if p[i] < m:
			m = p[i]
			idx = i
		l.append((m, idx))
	m = 10 ** 18
	idx = -1
	r = []
	for i in range(n - 1, -1, -1):
		if p[i] < m:
			m = p[i]
			idx = i
		r.append((m, idx))
	r.reverse()
	ans = []
	for i in range(1, n - 1):
		if l[i - 1][0] < p[i] > r[i + 1][0]:
			ans.append((l[i - 1][1] + 1, i + 1, r[i + 1][1] + 1))
	if len(ans) == 0:
		print('NO')
	else:
		print('YES')
		print(*ans[0])


def result(arr):
	(i, j, k) = (0, 1, 2)
	while k < len(arr):
		if arr[i] < arr[j] and arr[j] > arr[k]:
			return [i + 1, j + 1, k + 1]
		(i, j, k) = (i + 1, j + 1, k + 1)
	return [-1]
for _ in range(int(input())):
	a = int(input())
	arr = [int(i) for i in input().split()]
	if len(result(arr)) == 1:
		print('NO')
	else:
		print('YES')
		print(*result(arr))


from collections import Counter
for _ in range(int(input())):
	n = int(input())
	ar = list(map(int, input().split()))
	mini = n + 1
	maxi = -1
	min1 = 0
	max1 = 0
	li = []
	flag = 0
	for i in range(n):
		if mini >= ar[i]:
			min1 = 1
			li.append(i + 1)
			mini = ar[i]
		elif maxi <= ar[i]:
			max1 = 1
			mini = ar[i]
			min1 = 0
			li.append(i + 1)
			maxi = ar[i]
		if min1 == 1 and max1 == 1:
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(*li[-3:])
	else:
		print('NO')


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	minsuffix = [10 ** 18] * n
	minsuffix[n - 1] = arr[n - 1]
	ans = 'NO'
	for i in range(n - 2, -1, -1):
		minsuffix[i] = min(minsuffix[i + 1], arr[i])
	(i, j) = (0, 1)
	while i < n and j < n:
		if arr[i] < arr[j] and j + 1 < n and (minsuffix[j + 1] < arr[j]):
			ans = 'YES'
			print(ans)
			temp = arr[j + 1:]
			print(i + 1, j + 1, temp.index(min(temp)) + j + 2)
			break
		elif arr[i] > arr[j]:
			i += 1
			j += 1
		else:
			j += 1
	if ans == 'NO':
		print(ans)


from sys import stdin

def inp():
	return stdin.buffer.readline().rstrip().decode('utf8')

def itg():
	return int(stdin.buffer.readline())

def mpint():
	return map(int, stdin.buffer.readline().split())
for case in range(itg()):
	n = itg()
	arr = tuple(mpint())
	ans = [0]
	for i in range(1, n):
		if len(ans) == 1:
			if arr[ans[-1]] < arr[i]:
				ans.append(i)
			else:
				ans[-1] = i
		elif len(ans) == 2:
			if arr[ans[-1]] > arr[i]:
				ans.append(i)
				break
			ans[-1] = i
	if len(ans) == 3:
		print('YES')
		ans = map(lambda x: x + 1, ans)
		print(*ans)
	else:
		print('NO')


import math
from collections import *
import sys
from functools import reduce

def get_ints():
	return map(int, input().strip().split())

def get_list():
	return list(get_ints())

def get_string():
	return list(input().strip().split())

def printxsp(*args):
	return print(*args, end='')

def printsp(*args):
	return print(*args, end=' ')
DIRECTIONS = [[0, 1], [0, -1], [1, 0], [1, -1]]
NEIGHBOURS = [(i, j) for i in range(-1, 2) for j in range(-1, 2) if i != 0 or j != 0]
OrdUnicode_a = ord('a')
OrdUnicode_A = ord('A')
CAPS_ALPHABETS = {chr(i + OrdUnicode_A): i for i in range(26)}
SMOL_ALPHABETS = {chr(i + OrdUnicode_a): i for i in range(26)}
MOD_JOHAN = int(1000000000.0) + 7
MOD_LIGHT = 998244353
INFINITY = float('inf')
MAXN_EYEPATCH = int(100000.0) + 1
MAXN_FULLMETAL = 501
for _testcases_ in range(int(input())):
	n = int(input())
	li = get_list()
	flag = False
	for i in range(1, n - 1):
		if li[i + 1] < li[i] and li[i - 1] < li[i]:
			flag = True
			print('YES')
			print(i, i + 1, i + 2)
			break
	if not flag:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	yep = False
	for i in range(0, n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			yep = True
			break
	if not yep:
		print('NO')


n = int(input())
a = []
for i in range(n):
	k = input()
	a.append([int(n) for n in input().rstrip().split()])
for i in a:
	(l, m, r) = (float('inf'), -float('inf'), float('inf'))
	for j in range(len(i)):
		if m != -float('inf'):
			if i[j] < m:
				print('YES')
				print(i.index(l) + 1, i.index(m) + 1, j + 1)
				break
		if i[j] < l and m != float('inf'):
			l = i[j]
		if i[j] > l:
			m = i[j]
		if j == len(i) - 1:
			print('NO')


for _ in range(int(input())):
	n = int(input())
	(p, q, r) = (0, 0, 0)
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			(p, q, r) = (i, i + 1, i + 2)
			break
	if p * q * r != 0:
		print('YES')
		print(p, q, r)
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(x) for x in input().split()]
	forward = [0 for _ in range(n)]
	backward = [0 for _ in range(n)]
	for i in range(n):
		if i == 0:
			forward[i] = n + 1
			backward[n - 1 - i] = n + 1
		else:
			forward[i] = min(forward[i - 1], a[i - 1])
			backward[n - 1 - i] = min(backward[n - i], a[n - i])
	cflag = True
	for i in range(n):
		if a[i] > forward[i] and a[i] > backward[i]:
			print('YES')
			print(1 + a.index(forward[i]), 1 + i, 1 + a.index(backward[i]))
			cflag = False
			break
	if cflag:
		print('NO')


def solve():
	n = int(input())
	a = [int(x) for x in input().split()]
	for x in range(1, n - 1):
		if a[x] > a[x - 1] and a[x] > a[x + 1]:
			print('YES')
			return '{} {} {}'.format(x, x + 1, x + 2)
	return 'NO'
for q in range(int(input())):
	print(solve())


t = int(input())
while t > 0:
	t -= 1
	size = int(input())
	arr = [int(x) for x in input().split()]
	flag = False
	for mid in range(len(arr[1:-1])):
		(i, k) = (None, None)
		j = mid + 1
		jval = arr[mid + 1]
		for l in range(len(arr[:j])):
			if arr[l] < jval:
				i = l
				break
		for r in range(len(arr[j + 1:])):
			if arr[r + j + 1] < jval:
				k = r + j + 1
				break
		if i != None and k != None:
			flag = True
			print('YES')
			print(i + 1, j + 1, k + 1)
			break
	if flag == False:
		print('NO')


from collections import Counter
import math
import sys
from bisect import bisect, bisect_left, bisect_right

def input():
	return sys.stdin.readline().strip()

def INT():
	return int(input())

def MAP():
	return map(int, input().split())

def LIST(N=None):
	return list(MAP()) if N is None else [INT() for i in range(N)]

def mod():
	return 10 ** 9 + 7
for i in range(INT()):
	n = INT()
	arr = LIST()
	d = {}
	flag = 0
	for i in range(1, n):
		ans = [0, i + 1, 0]
		x = arr[i]
		for j in range(0, i):
			if arr[j] < x:
				ans[0] = j + 1
				break
		for j in range(i + 1, n):
			if arr[j] < x:
				ans[2] = j + 1
				break
		if ans[0] != 0 and ans[-1] != 0:
			print('YES')
			print(*ans)
			flag = 1
			break
	if flag == 0:
		print('NO')


cases = int(input())
for case in range(cases):
	n = int(input())
	list_num = list(map(lambda x: int(x), input().split()))
	unchanged = list.copy(list_num)
	maximum = n
	pos_max = list_num.index(maximum)
	length = len(list_num)
	flush_counter = 0
	for i in range(n):
		if list_num[i] == i + 1:
			flush_counter += 1
	reverse_flush_counter = 0
	for j in range(1, n + 1):
		if list_num[-j] == j:
			reverse_flush_counter += 1
	if flush_counter == n or reverse_flush_counter == n:
		print('NO')
		continue
	while (pos_max == 0 or pos_max == length - 1) and length >= 3:
		list_num.remove(maximum)
		maximum -= 1
		length -= 1
		pos_max = list_num.index(maximum)
	if length > 2:
		pos_left = unchanged.index(list_num[0]) + 1
		pos_right = unchanged.index(list_num[-1]) + 1
		pos_middle = unchanged.index(maximum) + 1
		print('YES')
		print(pos_left, pos_middle, pos_right)
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	array = [int(s) for s in input().split()]
	flag = False
	for i in range(len(array) - 2):
		if array[i] < array[i + 1] and array[i + 1] > array[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			flag = True
			break
	if not flag:
		print('NO')


T = input()
T = int(T)

def solve(n, perm):
	p_i = perm[0]
	for i in range(1, n):
		if perm[i] < p_i:
			p_i = perm[i]
		else:
			break
	p_j = perm[i]
	if p_i >= p_j:
		print('NO')
		return
	if i == n - 1:
		print('NO')
		return
	for j in range(i + 1, n):
		if perm[j] > p_j:
			p_j = perm[j]
		else:
			break
	p_k = perm[j]
	if p_j <= p_k:
		print('NO')
		return
	print('YES')
	print(' '.join([str(i), str(j), str(j + 1)]))
	return
for i in range(T):
	n = input()
	n = int(n)
	perm = list(map(int, input().split()))
	solve(n, perm)


MAX = 10 ** 9
MIN = -MAX
for t in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	left = [MAX]
	mini = MAX
	idx = None
	for i in range(n):
		if arr[i] < mini:
			mini = arr[i]
			idx = i + 1
		left.append((mini, idx))
	right = [MAX]
	mini = MAX
	for i in range(n - 1, -1, -1):
		if arr[i] < mini:
			mini = arr[i]
			idx = i + 1
		right.append((mini, idx))
	right = list(reversed(right))
	for i in range(1, n - 1):
		(a, aidx) = left[i]
		(b, bidx) = (arr[i], i + 1)
		(c, cidx) = right[i + 1]
		if a < b > c:
			print('YES')
			print(aidx, bidx, cidx)
			break
	else:
		print('NO')


for t in range(int(input())):
	n = int(input())
	a = [int(s) for s in input().split()]
	previous = 1 if a[0] < a[1] else -1
	for i in range(1, n - 1):
		if a[i] > a[i + 1] and previous == 1:
			print('YES')
			print(i, i + 1, i + 2)
			break
		else:
			previous = 1 if a[i] < a[i + 1] else -1
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	(l, r) = (0, n)
	f = 0
	d = 0
	ans = []
	for i in range(n, 0, -1):
		x = p[l:r].index(i)
		if x == 0:
			l += 1
		elif x == n - 1 - l - d:
			r -= 1
			d += 1
		else:
			f = 1
			ans = [l + 1, x + l + 1, r]
			break
		if r - l < 2:
			break
	if f == 1:
		print('YES')
		print(*ans)
	else:
		print('NO')


t = int(input())
while t > 0:
	n = int(input())
	a = list(map(int, input().split()))
	res = []
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(str(i) + ' ' + str(i + 1) + ' ' + str(i + 2))
			break
	else:
		print('NO')
	t -= 1


CASES = int(input())
for i in range(CASES):
	n = int(input())
	s = list(map(int, input().split()))
	for j in range(n - 2):
		if s[j] < s[j + 1] and s[j + 1] > s[j + 2]:
			print('Yes')
			print(j + 1, j + 2, j + 3)
			break
	else:
		print('No')


def sint():
	return int(input())

def sints():
	return map(int, input().split())

def sara():
	return list(map(int, input().split()))

def sstr():
	s = input()
	return list(s[:len(s)])

def main():
	tt = sint()
	while tt:
		tt -= 1
		n = sint()
		ara = sara()
		flg = 0
		for i in range(n - 2):
			if ara[i + 1] > ara[i] and ara[i + 1] > ara[i + 2]:
				print('YES')
				print(f'{i + 1} {i + 2} {i + 3}')
				flg = 1
				break
		if not flg:
			print('NO')
main()


a = []
t = int(input())
for i in range(t):
	n = int(input())
	a.append(list(map(lambda x: int(x), input().split(' '))))
for i in a:
	flag = False
	for j in range(2, len(i)):
		if i[j - 1] > i[j - 2] and i[j - 1] > i[j]:
			print('YES\n%d %d %d' % (j - 1, j, j + 1))
			flag = True
			break
	if not flag:
		print('NO')


from collections import deque
t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	suffMin = a[0]
	prefMin = a[-1]
	pref = []
	suff = []
	for i in range(n - 2):
		if suffMin > a[i]:
			suff.append(a[i])
			suffMin = a[i]
		else:
			suff.append(suffMin)
	for j in range(n - 1, 1, -1):
		if prefMin > a[j]:
			pref.append(a[j])
			prefMin = a[j]
		else:
			pref.append(prefMin)
	flag = 1
	pref = list(reversed(pref))
	for i in range(1, n - 1):
		if suff[i - 1] < a[i] > pref[i - 1]:
			print('YES')
			print(a.index(suff[i - 1]) + 1, i + 1, a.index(pref[i - 1]) + 1)
			flag = 0
			break
	if flag:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	f = 0
	lst = list(map(int, input().strip().split(' ')))
	for j in range(1, n - 1):
		if lst[j] > lst[j + 1] and lst[j] > lst[j - 1]:
			print('yes')
			print(j, j + 1, j + 2, end=' ')
			print()
			f = 1
			break
	if f == 0:
		print('no')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	l = [0] * n
	r = [0] * n
	l[0] = a[0]
	r[n - 1] = a[n - 1]
	(c, d, e) = (-1, -1, -1)
	for i in range(1, n):
		l[i] = min(a[i], l[i - 1])
	for i in range(n - 2, -1, -1):
		r[i] = min(r[i + 1], a[i])
	fg = 0
	for i in range(1, n - 1):
		if a[i] > l[i - 1] and a[i] > r[i + 1]:
			c = i
			fg = 1
			d = a.index(l[i - 1])
			e = a.index(r[i + 1])
			break
	if fg == 0:
		print('NO')
	else:
		print('YES')
		print(d + 1, c + 1, e + 1)


t = int(input())
for _ in range(t):
	h = False
	a = int(input())
	l = list(map(int, input().split()))
	for i in range(len(l) - 2):
		if l[i + 1] > max(l[i], l[i + 2]):
			h = True
			x = i
			break
	if h == True:
		print('YES')
		print(x + 1, x + 2, x + 3)
	else:
		print('NO')


from sys import stdin, stdout
import math, sys
from itertools import permutations, combinations
from collections import defaultdict, deque, OrderedDict
from os import path
import bisect as bi
import heapq

def yes():
	print('YES')

def no():
	print('NO')
if path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

	def I():
		return int(input())

	def In():
		return map(int, input().split())
else:

	def I():
		return int(stdin.readline())

	def In():
		return map(int, stdin.readline().split())

def dict(a):
	d = {}
	for x in a:
		if d.get(x, -1) != -1:
			d[x] += 1
		else:
			d[x] = 1
	return d

def main():
	try:
		n = I()
		l = list(In())
		ans = -1
		for x in range(1, n - 1):
			if l[x - 1] < l[x] and l[x] > l[x + 1]:
				ans = x
				break
		if ans == -1:
			no()
		else:
			yes()
			print(ans, ans + 1, ans + 2)
	except:
		pass
M = 998244353
P = 1000000007
for _ in range(I()):
	main()


t = int(input())
for i in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	maxs = 0
	maxin = -1
	for i in range(1, len(p) - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	aj = 0
	for j in range(n - 2):
		if p[j] < p[j + 1] and p[j + 1] > p[j + 2]:
			aj = 37
			l = [j + 1, j + 2, j + 3]
	if aj == 37:
		print('YES')
		print(*l)
	else:
		print('NO')


import math
n1 = int(input())
for x in range(n1):
	a = int(input())
	b = input()
	d = b.split(' ')
	arr = []
	for y in range(a):
		arr.append(int(d[y]))
	test = 'NO'
	for y in range(1, a - 1):
		if arr[y] > arr[y - 1] and arr[y] > arr[y + 1]:
			print('YES')
			print(y, y + 1, y + 2, end=' ')
			test = 'YES'
			print(' ')
			break
	if test == 'NO':
		print(test)


for _ in range(int(input())):
	len_sequence = int(input())
	sequence = [int(n) for n in input().split()]
	i = 0
	j = 0
	k = 0
	for m in range(len_sequence):
		if i == 0:
			i = m + 1
			continue
		if j == 0:
			if sequence[m] > sequence[i - 1]:
				j = m + 1
			else:
				i = m + 1
				j = 0
			continue
		if k == 0:
			if sequence[j - 1] > sequence[m]:
				k = m + 1
				break
			else:
				j = m + 1
	else:
		print('NO')
		continue
	print('YES')
	print(i, j, k)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().strip().split()))[:n]
	c = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			c += 1
			x = i
	if c > 0:
		print('YES')
		print(x, x + 1, x + 2)
	else:
		print('NO')


def tre(arr, n):
	(i, x) = (1, 0)
	while i < n - 1:
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			x = 1
			break
		i += 1
	if x == 0:
		print('NO')
for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	tre(arr, n)


import os
import re
import sys
from bisect import bisect, bisect_left, insort, insort_left
from collections import Counter, defaultdict, deque
from copy import deepcopy
from decimal import Decimal
from fractions import gcd
from io import BytesIO, IOBase
from itertools import accumulate, combinations, combinations_with_replacement, groupby, permutations, product
from math import acos, asin, atan, ceil, cos, degrees, factorial, hypot, log2, pi, radians, sin, sqrt, tan
from operator import itemgetter, mul
from string import ascii_lowercase, ascii_uppercase, digits

def inp():
	return int(input())

def inlist():
	return list(map(int, input().split()))

def instr():
	s = input()
	return list(s[:len(s)])

def invr():
	return map(int, input().split())

def main():
	t = inp()
	for _ in range(t):
		flag = False
		n = inp()
		a = inlist()
		for i in range(1, n - 1):
			if a[i - 1] < a[i] and a[i] > a[i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				flag = True
				break
		if flag == False:
			print('NO')
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))

def input():
	return sys.stdin.readline().rstrip('\r\n')
main()


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	arr = []
	key = 0
	for i in range(1, n):
		if l[i] - l[i - 1] > 0:
			arr.append('+')
		else:
			arr.append('-')
	for i in range(1, n - 1):
		if arr[i] == '-' and arr[i - 1] == '+':
			print('YES')
			print(i, i + 1, i + 2)
			key = 1
			break
	if key == 0:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	flag = False
	for i in range(1, n - 1):
		if p[i] > p[i - 1]:
			for j in range(i + 1, n):
				if p[j] < p[i]:
					print('YES')
					print(i, i + 1, j + 1)
					flag = True
					break
		if flag:
			break
	else:
		print('NO')


for _ in range(int(input())):
	input()
	z = list(map(int, input().split()))
	(a, b, c, d) = (z[0], None, None, [1])
	for i in range(1, len(z)):
		if b == None:
			if z[i] < a:
				d[0] = i + 1
				a = z[i]
			else:
				d.append(i + 1)
				b = z[i]
		elif z[i] > b:
			d[1] = i + 1
			b = z[i]
		else:
			c = z[i]
			d.append(i + 1)
			break
	if len(d) != 3:
		print('NO')
	else:
		print('YES')
		print(*d)


for _ in range(int(input())):
	inp = int(input())
	l = list(map(int, input().split()))
	num = 1
	while num + 1 < inp:
		if l[num - 1] < l[num] and l[num + 1] < l[num]:
			print('YES')
			print(num, num + 1, num + 2)
			break
		num += 1
	else:
		print('NO')


from sys import stdin, stdout
import heapq
import cProfile
from collections import Counter, defaultdict, deque
from functools import reduce
import math

def get_int():
	return int(stdin.readline().strip())

def get_tuple():
	return map(int, stdin.readline().split())

def get_list():
	return list(map(int, stdin.readline().split()))

def solve():
	n = int(input())
	ls = get_list()
	f = 1
	for (i, val) in enumerate(ls[1:n - 1], 1):
		if ls[i - 1] < val > ls[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			f = 0
			break
	if f:
		print('NO')

def main():
	solve()
TestCases = True
if TestCases:
	for i in range(get_int()):
		main()
else:
	main()


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	ft = -1
	bt = -1
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			ft = i - 1
			bt = i + 1
			break
	if ft == -1 or bt == -1:
		print('NO')
	else:
		print('YES')
		print(ft + 1, i + 1, bt + 1)


import math
t = int(input())
for w in range(t):
	n = int(input())
	l = [int(i) for i in input().split()]
	ans = 'NO'
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			t1 = (i, i + 1, i + 2)
			ans = 'YES'
			break
	print(ans)
	if ans == 'YES':
		print(t1[0], t1[1], t1[2])


from __future__ import division, print_function
from fractions import Fraction
import sys
import os
from io import BytesIO, IOBase
from itertools import *
import bisect
from heapq import *
from math import *
from collections import deque
from collections import Counter as counter
from itertools import combinations as comb
from itertools import permutations as permutate
from bisect import bisect_left as bl
from bisect import bisect_right as br
from bisect import bisect
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')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
mod = 1000000007

def inp():
	return sys.stdin.readline().rstrip('\r\n')

def out(var):
	sys.stdout.write(str(var))

def lis():
	return list(map(int, inp().split()))

def stringlis():
	return list(map(str, inp().split()))

def sep():
	return map(int, inp().split())

def strsep():
	return map(str, inp().split())

def zerolist(n):
	return [0] * n

def nextline():
	out('\n')

def testcase(t):
	for p in range(t):
		solve()

def printlist(a):
	for p in range(0, len(a)):
		out(str(a[p]) + ' ')

def lcm(a, b):
	return a * b // gcd(a, b)

def power(a, b):
	ans = 1
	while b > 0:
		if b % 2 == 1:
			ans *= a
		a *= a
		b //= 2
	return ans

def ncr(n, r):
	return factorial(n) // (factorial(r) * factorial(max(n - r, 1)))

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	i = 5
	while i * i <= n:
		if n % i == 0 or n % (i + 2) == 0:
			return False
		i = i + 6
	return True

def solve():
	n = int(inp())
	a = lis()
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
testcase(int(inp()))


t = int(input())
for _ in range(t):
	n = int(input())
	P = list(map(int, input().split()))
	L = [[0] * 2 for i in range(n)]
	R = [[0] * 2 for i in range(n)]
	min_ = 10 ** 18
	idx = -1
	for i in range(n):
		if P[i] <= min_:
			min_ = P[i]
			idx = i
		L[i][0] = min_
		L[i][1] = idx
	min_ = 10 ** 18
	idx = -1
	for i in range(n):
		if P[n - 1 - i] <= min_:
			min_ = P[n - 1 - i]
			idx = n - 1 - i
		min_ = min(min_, P[n - 1 - i])
		R[n - 1 - i][0] = min_
		R[n - 1 - i][1] = idx
	for i in range(n):
		if P[i] > L[i][0] and P[i] > R[i][0]:
			print('YES')
			print(L[i][1] + 1, i + 1, R[i][1] + 1)
			break
	else:
		print('NO')


z = input
mod = 10 ** 9 + 7
from collections import *
from queue import *
from sys import *
from collections import *
from math import *
from heapq import *
from itertools import *
from bisect import *
from collections import Counter as cc
from math import factorial as f

def lcd(xnum1, xnum2):
	return xnum1 * xnum2 // gcd(xnum1, xnum2)
for _ in range(int(z())):
	n = int(z())
	l = list(map(int, z().split()))
	for i in range(1, n - 1):
		lx = min(l[:i])
		ly = min(l[i + 1:])
		if l[i] > lx and l[i] > ly:
			print('YES')
			print(l.index(lx) + 1, i + 1, l.index(ly) + 1)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	b = list(map(int, input().split()))
	(i, j, k) = (0, 1, 2)
	while k < n:
		if b[i] < b[j] and b[j] > b[k]:
			print('YES')
			print(i + 1, j + 1, k + 1)
			break
		i += 1
		j += 1
		k += 1
	else:
		print('NO')


from collections import deque
import os
import sys
from io import BytesIO, IOBase
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')

def main():
	for t in range(int(input())):
		n = int(input())
		l = [int(j) for j in input().split()]
		sm = []
		tmp = 1e+18
		for i in range(n):
			sm.append(tmp)
			tmp = min(tmp, l[i])
		tmp = 1e+18
		lg = []
		for j in range(n - 1, -1, -1):
			lg.append(tmp)
			tmp = min(tmp, l[j])
		for i in range(n):
			if l[i] > sm[i] and l[i] > lg[n - i - 1]:
				print('YES')
				print(l.index(sm[i]) + 1, i + 1, l.index(lg[n - i - 1]) + 1)
				break
		else:
			print('NO')
main()


tc = int(input())
for _ in range(tc):
	n = int(input())
	arr = list(map(int, input().split()))
	flag = 0
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = 1
			break
	if not flag:
		print('NO')


x = int(input())
for d in range(x):
	found = False
	l = int(input())
	s = input().split()
	for n in range(l):
		s[n] = int(s[n])
	for i in range(1, l - 1):
		if s[i - 1] < s[i] and s[i] > s[i + 1] and (not found):
			print('YES')
			print(str(i), str(i + 1), str(i + 2))
			found = True
	if not found:
		print('NO')


def find(perm):
	for j in range(1, n - 1):
		if perm[j - 1] < perm[j] and perm[j] > perm[j + 1]:
			return (j, j + 1, j + 2)
	return (0, 0, 0)
T = int(input())
while T:
	n = int(input())
	P = list(input().split(' '))
	perm = list()
	for i in P:
		perm.append(int(i))
	P = None
	(a, b, c) = find(perm)
	if not a and (not b) and (not c):
		print('NO')
	else:
		print('YES')
		print(f'{a} {b} {c}')
	T = T - 1


t = int(input())
for case in range(t):
	n = int(input())
	s = input()
	l = [int(item) for item in s.split(' ')]
	i = 1
	while i <= n - 2:
		count = 0
		if min(l[i + 1:n]) < l[i]:
			count = count + 1
			a = l.index(min(l[i + 1:n]))
		if min(l[0:i]) < l[i]:
			count = count + 1
			b = l.index(min(l[0:i]))
		if count == 2:
			c = i
			break
		i = i + 1
	if count == 2:
		print('YES')
		print(b + 1, end=' ')
		print(c + 1, end=' ')
		print(a + 1)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	x = -1
	y = -1
	z = -1
	for i in range(1, n - 1):
		if a[i - 1] < a[i]:
			if a[i] > a[i + 1]:
				x = i
				y = i + 1
				z = i + 2
				break
	if (x != y and y != z) and x != -1:
		print('YES')
		print(x, y, z)
	else:
		print('NO')


import sys
import math
import random
input = sys.stdin.readline

def inp():
	return int(input())

def inara():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())
t = inp()
for _ in range(t):
	n = inp()
	ara = inara()
	ans = []
	for i in range(1, n - 1):
		if ara[i] > ara[i - 1] and ara[i] > ara[i + 1]:
			ans.append(i)
			ans.append(i + 1)
			ans.append(i + 2)
			break
	if len(ans) == 0:
		print('NO')
	else:
		print('YES')
		print(*ans)


T = int(input())
for t in range(T):
	n = int(input())
	a = list(map(int, input().split()))
	d = False
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i + 1] < a[i]:
			print('YES')
			print(i, i + 1, i + 2)
			d = True
			break
	if not d:
		print('NO')


def solve(t):
	if not t:
		return
	n = int(input())
	a = list(map(int, input().split()))
	flg = 0
	res_i = -1
	res_j = -1
	res_k = -1
	for j in range(1, n - 1):
		for i in range(0, j):
			if a[i] < a[j]:
				flg = 1
				break
		if not flg:
			continue
		for k in range(j + 1, n):
			if a[j] > a[k]:
				res_j = j
				res_i = i
				res_k = k
				flg = 2
				break
		if flg == 1:
			flg = 0
		elif flg == 2:
			break
	if res_i == -1:
		print('No')
	else:
		print('Yes\n%d %d %d' % (res_i + 1, res_j + 1, res_k + 1))
	solve(t - 1)
t = int(input())
solve(t)


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	z = int(input())
	c = 0
	x = list(map(int, input().split()))
	for i in range(1, z - 1):
		if x[i] > x[i - 1] and x[i] > x[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
		else:
			c += 1
	if c == z - 2:
		print('NO')


def create_max(arr):
	mx = [[arr[0], 0]]
	for i in range(1, len(arr)):
		mx.append(min(mx[-1], [arr[i], i]))
	return mx
for i in range(int(input())):
	n = int(input())
	arr = [int(i) for i in input().split()]
	mx1 = create_max(arr)
	mx2 = create_max(arr[::-1])[::-1]
	for i in range(1, len(arr) - 1):
		if mx1[i - 1][0] < arr[i] and mx2[i + 1][0] < arr[i]:
			print('YES')
			print(mx1[i - 1][1] + 1, i + 1, len(arr) - mx2[i + 1][1])
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	s = list(map(int, input().split()))
	c = 0
	for x in range(n - 2):
		if s[x + 1] > s[x] and s[x + 1] > s[x + 2]:
			print('YES')
			c += 1
			print(x + 1, end=' ')
			print(x + 2, end=' ')
			print(x + 3)
			break
	if c == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	l1 = []
	l2 = []
	f = 0
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			f = 1
			t1 = i
			t2 = i + 1
			t3 = i + 2
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(t1, t2, t3)


def read_list():
	return list(map(int, input().split(' ')))

def print_list(l):
	print(' '.join(map(str, l)))
N = int(input())
for _ in range(N):
	n = int(input())
	nums = read_list()
	p1 = 0
	p2 = None
	flag = True
	for i in range(1, n):
		if p2 and nums[i] < nums[p2]:
			flag = False
			print('YES')
			print('%d %d %d' % (p1 + 1, p2 + 1, i + 1))
			break
		if nums[i] > nums[p1] and (not p2 or nums[i] > nums[p2]):
			p2 = i
		elif nums[i] < nums[p1]:
			p1 = i
	if flag:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	m = 0
	flag = 0
	for i in range(1, n - 1):
		for j in range(i + 1, n):
			if a[i] > a[m] and a[i] > a[j]:
				flag = 1
				break
		if flag == 1:
			break
		if a[i] < a[m]:
			m = i
	if flag == 0:
		print('NO')
	else:
		print('YES')
		print(m + 1, i + 1, j + 1)


def func(arr):
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
n = int(input())
for _ in range(n):
	_ = input()
	arr = [int(i) for i in input().split()]
	func(arr)


from copy import deepcopy

def solve(n, num):
	nums = deepcopy(num)
	ind = nums.index(max(nums))
	while (ind == 0 or ind == len(nums) - 1) and len(nums) > 1:
		nums.pop(ind)
		ind = nums.index(max(nums))
	if len(nums) != 1:
		ret = max(nums)
		indexx = num.index(ret) + 1
		return f'YES\n{indexx - 1} {indexx} {indexx + 1}'
	return 'NO'
t = int(input())
for T in range(t):
	n = int(input())
	nums = list(map(int, input().split()))
	print(solve(n, nums))


for _ in range(0, int(input())):
	n = int(input())
	l = list(map(int, input().strip().split()))
	index_list = []
	for i in range(0, n):
		index_list.append([l[i], i])
	index_list.sort()
	index_list.reverse()
	curr_len = n
	first = 0
	last = n
	while True:
		if index_list == []:
			print('NO')
			break
		if index_list[0][1] in [first, last - 1]:
			r = index_list.pop(0)
			curr_len -= 1
			if r[1] == first:
				first += 1
			else:
				last -= 1
		else:
			print('YES')
			print(first + 1, index_list[0][1] + 1, last)
			break


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	leftv = p[0]
	lefti = 0
	rights = [(p[-1], n - 1)]
	f = True
	for i in range(n - 2, -1, -1):
		if p[i] < rights[-1][0]:
			rights.append((p[i], i))
		else:
			rights.append(rights[-1])
	for i in range(1, n - 1):
		if leftv < p[i] and p[i] > rights[n - i - 1][0]:
			print('yes')
			print(lefti + 1, i + 1, rights[n - i - 1][1] + 1)
			f = False
			break
		if p[i] < leftv:
			leftv = p[i]
			lefti = i
	if f:
		print('no')


for kek in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	flag = False
	ans = 0
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			flag = True
			ans = i + 1
			break
	if flag:
		print('YES')
		print(ans - 1, ans, ans + 1)
	else:
		print('NO')


t = int(input())
while t:
	t = t - 1
	n = int(input())
	a = list(map(int, input().split(' ')))
	b = sorted(a)
	c = b.reverse()
	if a == b or a == b.reverse():
		print('NO')
		continue
	x = 0
	y = 0
	z = 0
	flag = 0
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	if n < 3:
		print('NO')
		continue
	left_min = [p[0]]
	for i in range(1, n):
		left_min.append(min(left_min[-1], p[i]))
	right_min = [p[-1]]
	for i in reversed(range(n - 1)):
		right_min.append(min(right_min[-1], p[i]))
	j = -1
	for i in range(1, n - 1):
		if left_min[i - 1] < p[i] and right_min[n - (i + 1) - 1] < p[i]:
			j = i
	if j == -1:
		print('NO')
		continue
	print('YES')
	i_ans = 0
	for i in range(j):
		if p[i] < p[j]:
			i_ans = i
			break
	k_ans = 0
	for k in range(j + 1, n):
		if p[k] < p[j]:
			k_ans = k
			break
	print(f'{i_ans + 1} {j + 1} {k_ans + 1}')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	peaks = []
	up = False
	for i in range(n - 1):
		if l[i] < l[i + 1]:
			up = True
		else:
			if up:
				peaks.append(i)
			up = False
	if len(peaks) > 0:
		print('YES')
		print(peaks[0], peaks[0] + 1, peaks[0] + 2)
	else:
		print('NO')


import sys

def read():
	return sys.stdin.readline()

def write(*s):
	le = len(s)
	for i in range(le):
		sys.stdout.write(str(s[i]))
		if i != le - 1:
			sys.stdout.write(' ')

def main():
	t = int(read())
	for tt in range(t):
		n = int(read())
		p = list(map(int, read().split()))
		min_left = [0] * n
		min_right = [n - 1] * n
		for i in range(1, n):
			pr = min_left[i - 1]
			min_left[i] = pr if p[pr] < p[i] else i
		for i in range(n - 2, 0, -1):
			pr = min_right[i + 1]
			min_right[i] = pr if p[pr] < p[i] else i
		ok = False
		for j in range(1, n - 1):
			i = min_left[j - 1]
			k = min_right[j + 1]
			if p[i] < p[j] and p[j] > p[k]:
				write('YES\n')
				write(i + 1, j + 1, k + 1, '\n')
				ok = True
				break
		if not ok:
			write('NO\n')
main()


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().strip().split(' ')))
	m = max(arr)
	f = 0
	for i in range(1, len(arr) - 1, 1):
		if (arr[i] > arr[i - 1]) & (arr[i] > arr[i + 1]):
			print('YES')
			print(f'{i} {i + 1} {i + 2}')
			f = 1
			break
	if f == 1:
		continue
	else:
		print('NO')


t = int(input())
for u in range(t):
	n = int(input())
	a = [int(x) for x in input().split()]
	check = False
	k = 0
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			check = True
			k = i + 1
	if check:
		print('YES')
		print(k - 1, k, k + 1)
	else:
		print('NO')


from sys import stdin, gettrace
if gettrace():
	inputi = input
else:

	def input():
		return next(stdin)[:-1]

	def inputi():
		return stdin.buffer.readline()

def solve():
	n = int(inputi())
	aa = [int(a) for a in inputi().split()]
	for i in range(1, n - 1):
		if aa[i - 1] < aa[i] and aa[i] > aa[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')

def main():
	t = int(inputi())
	for _ in range(t):
		solve()
main()


from sys import stdin
T = int(stdin.readline().strip())
for caso in range(T):
	n = int(stdin.readline().strip())
	s = list(map(int, stdin.readline().strip().split()))
	mp = [0 for i in range(n + 1)]
	for i in range(n):
		mp[s[i]] = i
	x = 0
	y = n - 1
	f = False
	ans = []
	for i in range(n, 0, -1):
		if y - x < 2:
			break
		if mp[i] == x:
			x += 1
			continue
		if mp[i] == y:
			y -= 1
			continue
		ans = [x + 1, mp[i] + 1, y + 1]
		f = True
		break
	if f:
		print('YES')
		print(*ans)
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	ran = list(map(int, input().split()))
	yos = 0
	for j in range(1, n - 1):
		if ran[j] > ran[j - 1] and ran[j] > ran[j + 1]:
			yos = 1
			print('YES')
			print(j, j + 1, j + 2)
			break
	if yos == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	flag = False
	for i in range(1, n - 1):
		if a[i] > a[i + 1] and a[i] > a[i - 1]:
			s = i - 1
			k = i + 1
			flag = True
			break
	if flag:
		print('YES')
		print(s + 1, end=' ')
		print(i + 1, end=' ')
		print(k + 1)
	else:
		print('NO')


r = int(input())
i = 0
while i < r:
	n = int(input())
	p = list(map(int, input().split()))
	q = [0] * 3
	found = False
	for j in range(1, n - 1):
		if p[j] > p[j - 1] and p[j] > p[j + 1]:
			q = [j, j + 1, j + 2]
			found = True
			break
	if not found:
		print('NO')
	else:
		print('YES')
		print(' '.join(map(str, q)))
	i = i + 1


t = int(input())
while t:
	n = int(input())
	num = list(map(int, input().split()))
	count = 0
	for i in range(n - 2):
		if num[i] < num[i + 1]:
			if num[i + 1] > num[i + 2]:
				print('YES')
				count = 1
				print(i + 1, i + 2, i + 3)
				break
	if count == 0:
		print('NO')
	t = t - 1


for _ in range(int(input())):
	n = int(input())
	x = list(map(int, input().split()))
	c = 0
	for j in range(1, len(x) - 1):
		if x[j] > x[j - 1] and x[j] > x[j + 1]:
			c = 1
			print('YES')
			print(j, j + 1, j + 2)
			break
	if c == 0:
		print('NO')


T = int(input())
for _ in range(T):
	n = int(input())
	s = list(map(int, input().split()))
	flag = 1
	for i in range(len(s) - 2):
		if s[i + 1] > s[i] and s[i + 1] > s[i + 2]:
			flag = 0
			a = [i + 1, i + 2, i + 3]
	if flag == 0:
		print('YES')
		print(*a)
	else:
		print('NO')


def three_indices(ind):
	for i in range(1, len(ind) - 1):
		if ind[i] > ind[i - 1] and ind[i] > ind[i + 1]:
			print('YES')
			print(f'{i} {i + 1} {i + 2}')
			return
	print('NO')
t = int(input())
for i in range(t):
	n = int(input())
	ind = list(map(int, input().split()))
	three_indices(ind)


t = int(input())
for _ in range(t):
	n = int(input())
	lst = list(map(int, input().split()))
	flag = 0
	for i in range(1, n - 1):
		if lst[i] > lst[i - 1] and lst[i] > lst[i + 1]:
			flag = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if flag == 0:
		print('NO')


n = int(input())
for i in range(n):
	_ = input()
	arr = list(map(int, input().split()))
	add_array = []
	first_i = 0
	second_i = -1
	third_i = -1
	for i in range(len(arr)):
		if second_i > 0:
			if arr[i] < arr[second_i]:
				third_i = i
				break
			else:
				second_i = i
		elif arr[i] > arr[first_i]:
			second_i = i
		else:
			second_i = -1
			first_i = i
	if third_i != -1:
		print('YES')
		print(first_i + 1, second_i + 1, third_i + 1)
	else:
		print('NO')


import sys
sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep='\n')

def II():
	return int(sys.stdin.readline())

def MI():
	return map(int, sys.stdin.readline().split())

def LI():
	return list(map(int, sys.stdin.readline().split()))

def LLI(rows_number):
	return [LI() for _ in range(rows_number)]

def SI():
	return sys.stdin.readline()[:-1]
for _ in range(II()):
	n = II()
	aa = LI()
	ll = [-1] * n
	mn = n + 1
	mni = -1
	for i in range(n):
		if aa[i] > mn:
			ll[i] = mni
		if aa[i] < mn:
			mn = aa[i]
			mni = i
	mn = n + 1
	mni = -1
	for i in range(n - 1, 0, -1):
		if aa[i] > mn and ll[i] != -1:
			print('YES')
			print(ll[i] + 1, i + 1, mni + 1)
			break
		if aa[i] < mn:
			mn = aa[i]
			mni = i
	else:
		print('NO')


t = int(input())
ar = []
for i in range(t):
	n = int(input())
	a = [int(i) for i in input().split()]
	b = []
	b.extend(a)
	a.sort()
	ver = ''
	s = ''
	flag = 0
	if b != a:
		for i in range(1, n - 1):
			if b[i - 1] < b[i] and b[i] > b[i + 1]:
				ver = 'YES'
				flag = 1
				s += str(i - 1 + 1) + ' ' + str(i + 1) + ' ' + str(i + 1 + 1)
				break
	if b == a or flag == 0:
		ver = 'NO'
	ar.append([ver, s])
for i in ar:
	print(i[0])
	print(i[1])


n = int(input())
for i in range(n):
	m = int(input())
	flag = 0
	a = [int(i) for i in input().split()]
	for j in range(1, len(a) - 1):
		if a[j - 1] < a[j] and a[j + 1] < a[j]:
			print('YES')
			print(j, j + 1, j + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


t = int(input())
while t > 0:
	n = int(input())
	p = list(map(int, input().split()))
	flag = True
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i + 1] < p[i]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = False
			break
	if flag == True:
		print('NO')
	t -= 1


(T,) = map(int, input().split())
for t in range(T):
	(N,) = map(int, input().split())
	X = list(map(int, input().split()))
	R = 0
	for i in range(N):
		b = X[i]
		a = c = -1
		for j in range(i):
			if X[j] < b:
				a = X[j]
				break
		for k in range(i + 1, N):
			if X[k] < b:
				c = X[k]
				break
		if a == -1 or c == -1:
			continue
		R = (j + 1, i + 1, k + 1)
		break
	if R:
		print('YES')
		print(*R)
	else:
		print('NO')


t = int(input())
while t:
	t += -1
	n = int(input())
	l = list(map(int, input().split()))
	(ind1, ind2, ind3) = (-1, -1, -1)
	check = 0
	for i in range(1, n - 1):
		c1 = 0
		ind2 = i + 1
		for j in range(i):
			if l[j] < l[i]:
				c1 = 1
				ind1 = j + 1
				break
		c2 = 0
		for j in range(i + 1, n):
			if l[i] > l[j]:
				c2 = 1
				ind3 = j + 1
				break
		if c1 and c2:
			check = 1
			break
	if check:
		print('YES')
		print(ind1, ind2, ind3)
	else:
		print('NO')


t = int(input())
for a in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	c = 0
	j = 1
	i = 0
	c2 = 0
	while j < n and c == 0:
		if p[i] < p[j]:
			ip = i
			jp = j
			c2 = 1
		if c2 == 1 and p[j] < p[jp]:
			c = 1
			ap = j
		i += 1
		j += 1
	if c == 1:
		print('YES')
		print(ip + 1, jp + 1, ap + 1)
	else:
		print('NO')


import sys
input = sys.stdin.buffer.readline

def prog():
	for _ in range(int(input())):
		n = int(input())
		nums = list(map(int, input().split()))
		ls = 1001
		idxs = 0
		rs = 1001
		idxr = 1001
		mins = [[] for i in range(n)]
		for i in range(n):
			if nums[i] < ls:
				ls = nums[i]
				idxs = i
			mins[i].append([ls, idxs])
		for i in range(n - 1, -1, -1):
			if nums[i] < rs:
				rs = nums[i]
				idxr = i
			mins[i].append([rs, idxr])
		found = False
		for i in range(n):
			if mins[i][0][0] < nums[i] > mins[i][1][0]:
				found = True
				break
		if found:
			print('YES')
			print(mins[i][0][1] + 1, i + 1, mins[i][1][1] + 1)
		else:
			print('NO')
prog()


import sys, math
t = int(sys.stdin.readline())
for _ in range(t):
	n = int(sys.stdin.readline())
	liste = list(map(int, sys.stdin.readline().split()))
	ans = 'NO'
	out = [0, 0, 0]
	pp = [10001] * n
	pg = [10001] * n
	val = [0, 0, 0]
	for j in range(1, n):
		pp[j] = min(pp[j - 1], liste[j - 1])
	for j in range(n - 2, -1, -1):
		pg[j] = min(pg[j + 1], liste[j + 1])
		if pg[j] < liste[j] and pp[j] < liste[j]:
			ans = 'YES'
			val = [pp[j], liste[j], pg[j]]
	for i in range(n):
		if liste[i] == val[0]:
			out[0] = i + 1
		if liste[i] == val[1]:
			out[1] = i + 1
		if liste[i] == val[2]:
			out[2] = i + 1
	print(ans)
	if ans == 'YES':
		print(*out)


for _ in range(0, int(input())):
	n = int(input())
	v = list(map(int, input().split()))
	m = M = [0, v[0]]
	for (i, x) in enumerate(v[1:-1], 1):
		if v[i] > v[i - 1] and v[i] > v[i + 1]:
			break
	if v[i] > v[i - 1] and v[i] > v[i + 1]:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


def main_function():
	t = int(input())
	output_list = []
	for i in range(t):
		input()
		p = [int(i) for i in input().split(' ')]
		for i in range(1, len(p) - 1):
			found_min_1 = False
			found_min_2 = False
			min_1 = -1000000
			min_2 = -10000000
			for d in range(len(p)):
				if d < i and p[i] > p[d]:
					found_min_1 = True
					min_1 = d
				elif d > i and p[i] > p[d]:
					found_min_2 = True
					min_2 = d
				if found_min_1 and found_min_2:
					output_list.append(f'YES\n{min_1 + 1} {i + 1} {min_2 + 1}')
					break
			if found_min_1 and found_min_2:
				break
		else:
			output_list.append('NO')
	return '\n'.join(output_list)
print(main_function())


for i in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	flag = False
	for i in range(1, len(arr) - 1, 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES', i, i + 1, i + 2, end='\n')
			flag = True
			break
	if flag == False:
		print('NO')


c = int(input())
for k in range(c):
	n = int(input())
	l = [int(i) for i in input().split()]
	i1 = n
	j1 = n
	for i in range(n - 1):
		if l[i] < l[i + 1]:
			i1 = i
			j1 = i + 1
			break
	j2 = -1
	k2 = -1
	for i in range(n - 1, 0, -1):
		if l[i] < l[i - 1]:
			k2 = i
			j2 = i - 1
			break
	if j2 < j1:
		print('NO')
	else:
		print('YES')
		i = i1 + 1
		k = k2 + 1
		j = j2
		if l[j1] > l[j2]:
			j = j1
		j += 1
		print(i, j, k)


import sys
input = sys.stdin.buffer.readline
t = int(input())
while t:
	t -= 1
	n = int(input())
	p = list(map(int, input().split()))
	max = n - 1
	min = 0
	smaller = [0] * 1000
	smaller[0] = -1
	for i in range(1, n):
		if p[i] <= p[min]:
			min = i
			smaller[i] = -1
		else:
			smaller[i] = min
	greater = [0] * 1000
	greater[n - 1] = -1
	for i in range(n - 2, -1, -1):
		if p[i] <= p[max]:
			max = i
			greater[i] = -1
		else:
			greater[i] = max
	for i in range(0, n):
		if smaller[i] != -1 and greater[i] != -1:
			print('yes')
			print(smaller[i] + 1, i + 1, greater[i] + 1)
			break
		elif i == n - 1:
			print('no')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	found = False
	for j in range(1, n - 1):
		if p[j] > p[j - 1] and p[j] > p[j + 1]:
			found = True
			print('YES')
			print(j, j + 1, j + 2)
			break
	if found == False:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	li = list(map(int, input().split()))
	p = 0
	for i in range(len(li)):
		if i == n - 2:
			break
		elif li[i] < li[i + 1] and li[i + 1] > li[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			p = 1
			break
	if p == 0:
		print('NO')


def threeIndex(arr, n):
	min1 = arr[0]
	max2 = 0
	min3 = 0
	a = b = c = 1
	flag = 0
	for i in range(1, n):
		if arr[i] < min1 and flag == 0:
			min1 = arr[i]
			a = i + 1
		elif arr[i] > min1 and arr[i] > max2:
			flag = 1
			max2 = arr[i]
			b = i + 1
		elif arr[i] < max2 and flag == 1:
			min3 = arr[i]
			c = i + 1
			break
	if min1 == 0 or max2 == 0 or min3 == 0:
		return
	return [a, b, c]
t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	res = threeIndex(arr, n)
	if res:
		print('YES')
		res.sort()
		for i in res:
			print(i, end=' ')
		print()
	else:
		print('NO')


from collections import defaultdict
import math
t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	flag = False
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] and arr[i] > arr[i + 1]:
			flag = True
			break
	if flag:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	arr = [int(x) for x in input().split()]
	i = j = k = 0
	s = 0
	for (idx, v) in enumerate(arr):
		if s == 0:
			if v <= arr[i]:
				i = idx
			else:
				j = idx
				s += 1
		elif s == 1:
			if v >= arr[j]:
				j = idx
			else:
				k = idx
				s += 1
				print('YES')
				print(f'{i + 1} {j + 1} {k + 1}')
				break
	if s != 2:
		print('NO')


def solve():
	global _, A
	okl = [None for _ in A]
	okr = [None for _ in A]
	mnl = A[0]
	li = 0
	for i in range(1, len(A)):
		if A[i] <= mnl:
			mnl = A[i]
			li = i
		else:
			okl[i] = li
	mnr = A[-1]
	ri = len(A) - 1
	for i in range(len(A) - 2, -1, -1):
		if A[i] <= mnr:
			mnr = A[i]
			ri = i
		else:
			okr[i] = ri
	for i in range(1, len(A) - 1):
		if not okr[i] is None and (not okl[i] is None):
			print('YES\n%d %d %d' % (okl[i] + 1, i + 1, okr[i] + 1))
			return
	print('NO')
for _ in range(int(input())):
	_ = int(input())
	A = list(map(int, input().split()))
	sol = solve()


def solve():
	n = int(input())
	array = list(map(int, input().split()))
	for i in range(1, n - 1):
		if array[i - 1] < array[i] and array[i] > array[i + 1]:
			print('YES')
			print('{} {} {}'.format(i, i + 1, i + 2))
			return
	print('NO')
t = int(input())
while t != 0:
	t -= 1
	solve()


T = int(input())
for _ in range(T):
	n = tuple(map(int, input().split()))
	x = list(map(int, input().split()))
	ok = False
	for i in range(1, len(x) - 1):
		if x[i - 1] < x[i] > x[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			ok = True
			break
	if ok:
		continue
	else:
		print('NO')


def main():
	t = int(input())
	for _ in range(t):
		n = int(input())
		s = list(map(int, input().split()))
		for i in range(1, n - 1):
			if s[i - 1] < s[i] > s[i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				break
		else:
			print('NO')
main()


import sys
inp = sys.stdin.readline
read = lambda : list(map(int, inp().strip().split()))

def solve():
	ans = ''
	for _ in range(int(input())):
		n = int(input())
		arr = read()
		arr2 = list(zip(arr, range(1, n + 1)))
		arr2.sort()
		f = 1
		mini = maxi = arr2[0][1]
		for i in range(1, n):
			if mini < arr2[i][1] < maxi:
				ans += 'YES\n'
				ans += str(mini) + ' ' + str(arr2[i][1]) + ' ' + str(maxi) + '\n'
				f = 0
				break
			mini = min(mini, arr2[i][1])
			maxi = max(maxi, arr2[i][1])
		if f:
			ans += 'NO\n'
	print(ans)
solve()


import sys
infile = sys.stdin
next(infile)
for line in infile:
	n = int(line)
	a = list(map(int, infile.readline().split()))
	indi = [0, 0, 0]
	k = 0
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			k += 1
			print('YES')
			indi[0] += i + 1
			indi[1] += i + 2
			indi[2] += i + 3
			print(*indi)
			break
	if k == 0:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	d = l[-1]
	x = [0] * n
	for i in range(n - 2, -1, -1):
		if l[i] > d:
			x[i] = 1
		d = min(d, l[i])
	d = l[0]
	(a, b, c) = (-1, -1, -1)
	for i in range(1, n):
		if x[i] and d < l[i]:
			b = i
			break
		d = min(d, l[i])
	if b == -1:
		print('NO')
	else:
		print('YES')
		a = i - 1
		while a >= 0 and l[a] >= l[b]:
			a -= 1
		c = b + 1
		while c < n and l[c] >= l[b]:
			c += 1
		print(a + 1, b + 1, c + 1)


t = int(input())
for testcase in range(t):
	n = int(input())
	A = list(map(int, input().split()))
	smallest = 1001
	largest = 0
	ii = 0
	j = 0
	k = 0
	for i in range(1, n - 1):
		left = False
		lefti = 0
		right = False
		righti = 0
		for j in range(0, i):
			if A[j] < A[i]:
				left = True
				lefti = j
				break
		if left:
			for k in range(i + 1, n):
				if A[k] < A[i]:
					right = True
					righti = k
					break
		if left and right:
			ii = lefti
			j = i
			k = righti
			break
	if left and right:
		print('YES')
		print(str(ii + 1) + ' ' + str(j + 1) + ' ' + str(k + 1))
	else:
		print('NO')


t = int(input())
for cases in range(t):
	n = int(input())
	arr = list(map(int, input().strip().split()))
	flag = 0
	(st, end) = (0, n - 1)
	for i in range(n, 0, -1):
		temp = arr.index(i)
		if temp == st:
			st += 1
		elif temp == end:
			end -= 1
		else:
			print('YES')
			print(temp, temp + 1, temp + 2)
			flag = 1
			break
	if not flag:
		print('NO')


def search(arr, x):
	n = len(arr)
	for i in range(n):
		if x > arr[i]:
			return i
	return -1
T = int(input())
for ii in range(T):
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		left = a[:i]
		right = a[i + 1:]
		k = search(left, a[i])
		l = search(right, a[i])
		if k != -1 and l != -1:
			print('YES')
			print(k + 1, i + 1, i + 2 + l)
			break
	else:
		print('NO')


for test in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	t = [a[i] < a[i + 1] for i in range(0, n - 1)]
	i = 1
	ok = True
	while ok and i < n - 1:
		while i < n - 1 and t[i]:
			i += 1
		if i < n - 1 and t[i - 1]:
			print('YES')
			print(i, i + 1, i + 2)
			ok = False
		i += 1
	if not ok:
		continue
	print('NO')


for _ in range(int(input())):
	n = int(input())
	ans = 'NO'
	num = list(map(int, input().split()))
	for i in range(1, n - 1):
		if num[i] > num[i - 1] and num[i] > num[i + 1]:
			ans = 'YES'
			print('YES')
			print(i, i + 1, i + 2)
			break
		else:
			ans = 'NO'
	if ans == 'NO':
		print('NO')


for x in range(int(input())):
	n = int(input())
	m = list(map(int, input().split()))
	a = []
	if m[1] > m[0]:
		a.append([1, 0])
	for i in range(1, n - 1):
		if m[i] > m[i - 1] and m[i] > m[i + 1]:
			a.append([i + 1, 1])
		elif m[i] < m[i - 1] and m[i] < m[i + 1]:
			a.append([i + 1, 0])
	if m[n - 2] > m[n - 1]:
		a.append([n, 0])
	if len(a) < 3:
		print('NO')
	else:
		for i in range(len(a) - 2):
			if a[i][1] == 0:
				print('YES')
				print(a[i][0], a[i + 1][0], a[i + 2][0])
				break


from sys import stdin
for _ in range(int(stdin.readline())):
	n = int(stdin.readline())
	lst = [int(i) for i in stdin.readline().split()]
	min1 = lst[0]
	max1 = None
	min2 = None
	nk = 0
	ii = 1
	jj = None
	kk = None
	for i in range(1, n):
		if lst[i] <= min1 and nk == 0:
			min1 = lst[i]
			ii = i + 1
		elif nk == 0:
			max1 = lst[i]
			nk = 1
			jj = i + 1
		elif max1 <= lst[i]:
			max1 = lst[i]
			jj = i + 1
		else:
			min2 = lst[i]
			kk = i + 1
			break
	if max1 == None or min2 == None:
		print('NO')
	else:
		print('YES')
		print(ii, jj, kk)


from sys import stdin, stdout
import math
from itertools import permutations, combinations
from collections import defaultdict
from collections import Counter
from bisect import bisect_left
import sys
from queue import PriorityQueue
import operator as op
from functools import reduce
mod = 1000000007

def L():
	return list(map(int, stdin.readline().split()))

def In():
	return map(int, stdin.readline().split())

def I():
	return int(stdin.readline())

def printIn(ob):
	return stdout.write(str(ob) + '\n')

def powerLL(n, p):
	result = 1
	while p:
		if p & 1:
			result = result * n % mod
		p = int(p / 2)
		n = n * n % mod
	return result

def ncr(n, r):
	r = min(r, n - r)
	numer = reduce(op.mul, range(n, n - r, -1), 1)
	denom = reduce(op.mul, range(1, r + 1), 1)
	return numer // denom

def myCode():
	n = input()
	lst = L()
	(x, y, z) = (0, 0, 0)
	for i in range(1, len(lst) - 1):
		x = lst.index(min(lst[0:i]))
		z = lst.index(min(lst[i + 1:len(lst)]))
		if lst[x] < lst[i] > lst[z]:
			print('YES')
			print(x + 1, i + 1, z + 1)
			return
	print('NO')

def main():
	x = I()
	for t in range(x):
		myCode()
main()


import time, math as mt, bisect, sys
from sys import stdin, stdout
from collections import deque
from fractions import Fraction
from collections import Counter
from collections import OrderedDict
pi = 3.141592653589793

def II():
	return int(stdin.readline())

def IO():
	return stdin.readline()

def IP():
	return map(int, stdin.readline().split())

def L():
	return list(map(int, stdin.readline().split()))

def P(x):
	return stdout.write(str(x) + '\n')

def PI(x, y):
	return stdout.write(str(x) + ' ' + str(y) + '\n')

def lcm(a, b):
	return a * b // gcd(a, b)

def gcd(a, b):
	if a == 0:
		return b
	elif b == 0:
		return a
	if a > b:
		return gcd(a % b, b)
	else:
		return gcd(a, b % a)

def readTree():
	v = int(input())
	adj = [set() for i in range(v + 1)]
	for i in range(v - 1):
		(u1, u2) = In()
		adj[u1].add(u2)
		adj[u2].add(u1)
	return (adj, v)

def bfs(adj, v):
	visited = [False] * (v + 1)
	q = deque()
	while q:
		pass

def sieve():
	li = [True] * 1000001
	(li[0], li[1]) = (False, False)
	for i in range(2, len(li), 1):
		if li[i] == True:
			for j in range(i * i, len(li), i):
				li[j] = False
	prime = []
	for i in range(1000001):
		if li[i] == True:
			prime.append(i)
	return prime

def setBit(n):
	count = 0
	while n != 0:
		n = n & n - 1
		count += 1
	return count
mx = 10 ** 7
spf = [mx] * (mx + 1)

def SPF():
	spf[1] = 1
	for i in range(2, mx + 1):
		if spf[i] == mx:
			spf[i] = i
			for j in range(i * i, mx + 1, i):
				if i < spf[j]:
					spf[j] = i
	return
mod = 10 ** 9 + 7

def solve():
	n = II()
	li = L()
	n1 = -1
	found = False
	for i in range(n):
		for j in range(i):
			if li[j] < li[i]:
				n1 = j
				break
		if n1 != -1:
			for k in range(i + 1, n):
				if li[k] < li[i]:
					print('YES')
					print(n1 + 1, i + 1, k + 1)
					found = True
					break
		if found:
			break
	else:
		print('NO')
t = II()
for i in range(t):
	solve()


for i in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	for i in range(len(l) - 2):
		if l[i] < l[i + 1] and l[i + 1] > l[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = input()
	a = list(map(int, input().split()))
	for i in range(1, len(a) - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			break
	else:
		print('NO')
		continue
	print('YES')
	print(i, i + 1, i + 2)


T = int(input())
for _ in range(T):
	ans = 0
	N = int(input())
	p = list(map(int, input().split()))
	flag = True
	for i in range(1, N - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = False
			break
	if flag:
		print('NO')


number_of_queries = int(input())
lista = []
for xx in range(number_of_queries):
	n = int(input())
	lista = [int(item) for item in input().split()]
	verificador = -1
	for i in range(n - 2):
		if lista[i] < lista[i + 1] and lista[i + 1] > lista[i + 2]:
			print('YES')
			print(i + 1, i + 1 + 1, i + 2 + 1)
			verificador = 1
			break
	if verificador == -1:
		print('NO')


t = int(input())
for ex in range(t):
	n = int(input())
	p = [int(i) for i in input().split()]
	max_not_in_the_middle = n
	found = False
	while max_not_in_the_middle > 0:
		ind = p.index(max_not_in_the_middle)
		if 0 < ind < len(p) - 1 and p[ind + 1] < p[ind] > p[ind - 1]:
			print('Yes')
			print(*[ind, ind + 1, ind + 2])
			found = True
			break
		else:
			max_not_in_the_middle -= 1
	if not found:
		print('No')


i = int(input())
while i > 0:
	i = i - 1
	c = int(input())
	v = list(map(int, input().strip().split()))[:c]
	f = 0
	h = 0
	w = c
	b = 1
	while b:
		if f + h < c and v[f] == w:
			f = f + 1
			w = w - 1
		elif f + h < c and v[c - 1 - h] == w:
			h = h + 1
			w = w - 1
		elif f + h < c:
			b = 0
			t = 0
			for q in range(c - f - h):
				if v[q + f] == w:
					t = q + f
					break
			print('YES')
			print(f + 1, t + 1, c - h)
		else:
			b = 0
			print('NO')


t = int(input())
while t > 0:
	t -= 1
	n = int(input())
	l1 = [int(i) for i in input().split(' ')]
	flag = 0
	for i in range(1, n - 1):
		if l1[i] > l1[i - 1] and l1[i] > l1[i + 1]:
			flag = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if flag == 0:
		print('NO')


import os, io
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	noAns = True
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(str(i) + ' ' + str(i + 1) + ' ' + str(i + 2))
			noAns = False
			break
	if noAns:
		print('NO')


import math
n = int(input())
for _ in range(n):
	a = int(input())
	lis = list(map(int, input().split()))
	z = 1
	i = lis[0]
	j = -1
	k = -1
	while z < a:
		if j == -1:
			if lis[z] > i:
				j = lis[z]
			else:
				i = lis[z]
		elif lis[z] < j:
			k = lis[z]
			break
		else:
			j = lis[z]
		z += 1
	if j == -1 or k == -1:
		print('NO')
	else:
		print('YES')
		print(lis.index(i) + 1, lis.index(j) + 1, lis.index(k) + 1)


import sys
input = sys.stdin.readline

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())
T = inp()
tests = []
for i in range(T):
	inp()
	tests.append(inlt())
for test in tests:
	for i in range(1, len(test) - 1):
		if test[i - 1] < test[i] and test[i] > test[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	mins_left = [0]
	for i in range(1, n):
		if p[i] < p[mins_left[i - 1]]:
			mins_left.append(i)
		else:
			mins_left.append(mins_left[i - 1])
	mins_right = [n - 1] * n
	for i in range(n - 2, -1, -1):
		if p[i] < p[mins_right[i + 1]]:
			mins_right[i] = i
		else:
			mins_right[i] = mins_right[i + 1]
	for i in range(1, n - 1):
		if p[i] > p[mins_left[i - 1]] and p[i] > p[mins_right[i + 1]]:
			print('YES')
			print(mins_left[i - 1] + 1, i + 1, mins_right[i + 1] + 1)
			break
	else:
		print('NO')


import sys
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	l = int(input())
	m = list(map(int, input().split()))
	best = 0
	for i in range(l):
		(ok, a, b) = (0, 0, 0)
		x = m[i]
		for j in range(i):
			if m[j] < m[i]:
				ok += 1
				a = j
				break
		for j in range(i + 1, l):
			if m[j] < m[i]:
				ok += 1
				b = j
				break
		best = max(best, ok)
		if ok == 2:
			print('YES')
			print(a + 1, i + 1, b + 1)
			break
	if best != 2:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = [int(x) for x in input().split()]
	j = -1
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			j = i
			break
	if j == -1:
		print('NO')
	else:
		print('YES')
		print(j, j + 1, j + 2)


T = int(input())
for t in range(T):
	N = int(input())
	nums = [int(c) for c in input().split()]
	tmp = [x for (x, y) in sorted(enumerate(nums), key=lambda x: x[1])]
	m = min(tmp[0], tmp[1])
	M = max(tmp[0], tmp[1])
	test = False
	for i in range(2, len(tmp)):
		if tmp[i] > m and tmp[i] < M:
			print('YES')
			print('{} {} {}'.format(m + 1, tmp[i] + 1, M + 1))
			test = True
			break
		else:
			m = min(m, tmp[i])
			M = max(M, tmp[i])
	if not test:
		print('NO')


I = lambda : list(map(int, input().split(' ')))
for _ in range(int(input())):
	n = int(input())
	lst = I()
	flag = 0
	for j in range(1, n - 1):
		a = j
		pj = lst[j]
		pi = None
		pk = None
		for i in range(j):
			if lst[i] < pj:
				pi = i
				break
		for i in range(j + 1, n):
			if lst[i] < pj:
				pk = i
				break
		if pi != None and pk != None:
			flag = 1
			print('YES')
			print(pi + 1, end=' ')
			print(a + 1, end=' ')
			print(pk + 1)
			break
	if not flag:
		print('NO')


def solve(n, a):
	for i in range(n - 2):
		if a[i] < a[i + 1] > a[i + 2]:
			return (i + 1, i + 2, i + 3)
	return -1
for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	s = solve(n, a)
	if s == -1:
		print('NO')
	else:
		print('YES')
		print(*s)


import math
t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	deck = 0
	(a_l, a_r) = (a[:n // 2], a[n // 2:])
	a_lnew = [0] * (n // 2)
	a_lnew = a_l[:]
	a_lnew.sort(reverse=True)
	a_rnew = [0] * math.ceil(n / 2)
	a_rnew = a_r[:]
	a_rnew.sort()
	if a_lnew == a_l and a_rnew == a_r:
		print('NO')
	else:
		for q in range(1, n - 1):
			if a[q - 1] < a[q] > a[q + 1]:
				print('YES')
				print(q, q + 1, q + 2)
				break
		else:
			print('NO')


for i in range(int(input())):
	n = int(input())
	li = list(map(int, input().split()))[:n]
	for j in range(1, n - 1):
		if li[j - 1] < li[j] > li[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			break
	else:
		print('NO')


import bisect
import os
import gc
import sys
from io import BytesIO, IOBase
from collections import Counter
from collections import deque
import heapq
import math
import statistics

def sin():
	return input()

def ain():
	return list(map(int, sin().split()))

def sain():
	return input().split()

def iin():
	return int(sin())
MAX = float('inf')
MIN = float('-inf')
MOD = 1000000007

def readTree(n, m):
	adj = [deque([]) for _ in range(n + 1)]
	for _ in range(m):
		(u, v) = ain()
		adj[u].append(v)
		adj[v].append(u)
	return adj

def main():
	for _ in range(iin()):
		n = iin()
		l = ain()
		flag = 0
		for i in range(1, n - 1):
			if l[i - 1] < l[i] > l[i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				flag = 1
				break
		if flag == 0:
			print('NO')
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')
main()


from sys import stdin
t = int(stdin.readline())
for _ in range(t):
	n = int(stdin.readline())
	arr = list(map(int, stdin.readline().rstrip().split(' ')))
	for j in range(n):
		flag1 = False
		flag2 = False
		idx1 = None
		idx2 = None
		for i in range(j):
			if arr[i] < arr[j]:
				flag1 = True
				idx1 = i + 1
				break
		if flag1:
			for k in range(j + 1, n):
				if arr[j] > arr[k]:
					flag2 = True
					idx2 = k + 1
					break
		if flag1 and flag2:
			print('YES')
			print(idx1, j + 1, idx2)
			break
	else:
		print('NO')


n = int(input())
for case in range(n):
	m = int(input())
	arr = list(map(int, input().split()))
	found = False
	for mid in range(m):
		ival = -1
		jval = -1
		for i in range(0, mid):
			if arr[i] < arr[mid]:
				ival = i
		for j in range(mid + 1, m):
			if arr[j] < arr[mid]:
				jval = j
		if ival != -1 and jval != -1:
			print('YES')
			print(ival + 1, mid + 1, jval + 1)
			found = True
			break
	if not found:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
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')

def fact(x):
	if x == 0:
		return 1
	else:
		return x * fact(x - 1)

def lower_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] >= num:
			answer = middle
			end = middle - 1
		else:
			start = middle + 1
	return answer

def upper_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] <= num:
			answer = middle
			start = middle + 1
		else:
			end = middle - 1
	return answer

def abs(x):
	return x if x >= 0 else -x

def binary_search(li, val, lb, ub):
	ans = 0
	while lb <= ub:
		mid = (lb + ub) // 2
		if li[mid] > val:
			ub = mid - 1
		elif val > li[mid]:
			lb = mid + 1
		else:
			ans = 1
			break
	return ans

def sieve_of_eratosthenes(n):
	ans = []
	arr = [1] * (n + 1)
	(arr[0], arr[1], i) = (0, 0, 2)
	while i * i <= n:
		if arr[i] == 1:
			j = i + i
			while j <= n:
				arr[j] = 0
				j += i
		i += 1
	for k in range(n):
		if arr[k] == 1:
			ans.append(k)
	return ans

def nc2(x):
	if x == 1:
		return 0
	else:
		return x * (x - 1) // 2

def kadane(x):
	sum_so_far = 0
	current_sum = 0
	for i in x:
		current_sum += i
		if current_sum < 0:
			current_sum = 0
		else:
			sum_so_far = max(sum_so_far, current_sum)
	return sum_so_far

def mex(li):
	check = [0] * 1001
	for i in li:
		check[i] += 1
	for i in range(len(check)):
		if check[i] == 0:
			return i

def sumdigits(n):
	ans = 0
	while n != 0:
		ans += n % 10
		n //= 10
	return ans
from math import *
for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	(x, y, z) = (0, 0, 0)
	f = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			f = 1
			x = i
			y = i + 1
			z = i + 2
	if f:
		print('yes')
		print(x, y, z)
	else:
		print('no')


t = int(input())
while t:
	n = int(input())
	x = [int(i) for i in input().split()]
	lol = False
	for i in range(1, len(x) - 1):
		if x[i - 1] < x[i] and x[i] > x[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			lol = True
			break
	if not lol:
		print('NO')
	t -= 1


for i in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	l = []
	d = 0
	j = 0
	for j in range(1, n - 1):
		if a[j] > a[j - 1] and a[j] > a[j + 1]:
			l.append(j)
			l.append(j + 1)
			l.append(j + 2)
			d = 1
			break
	if d == 1:
		print('YES')
		print(*l)
	else:
		print('NO')


def solve(arr):
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
for _ in range(int(input())):
	input()
	arr = [int(e) for e in input().split()]
	solve(arr)


def ans(l):
	f = 0
	for i in range(1, len(l) - 1, 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			return (i - 1 + 1, i + 1, i + 1 + 1)
	return False
t = int(input())
while t > 0:
	a = int(input())
	l = list(map(int, input().split()))
	if ans(l) != False:
		k = list(ans(l))
		print('YES')
		for i in k:
			print(i, end=' ')
		print()
	else:
		print('NO')
	t -= 1


for _ in range(int(input())):
	n = int(input())
	count = 0
	arr = list(map(int, input().split()))
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			count += 1
			break
	if count == 0:
		print('NO')


for _ in ' ' * int(input()):
	a = int(input())
	b = list(map(int, input().split()))
	c = b[0]
	z = [0] * a
	z1 = [0] * a
	for i in range(0, a):
		c = min(c, b[i])
		z[i] = c
	c = b[a - 1]
	for i in range(a - 1, -1, -1):
		c = min(c, b[i])
		z1[i] = c
	for i in range(1, a - 1):
		if b[i] != z[i] and b[i] != z[i]:
			if z[i] < b[i] > z1[i]:
				print('YES')
				print(b.index(z[i]) + 1, i + 1, b.index(z1[i]) + 1)
				break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(_) for _ in input().split()]
	found = False
	for i in range(n):
		l = i - 1
		while l >= 0:
			if a[l] < a[i]:
				break
			l -= 1
		r = i + 1
		while r < n:
			if a[i] > a[r]:
				break
			r += 1
		if l >= 0 and r < n:
			print('YES')
			print(l + 1, i + 1, r + 1)
			found = True
			break
	if found == False:
		print('NO')


for _ in range(int(input())):
	number_of_entries = int(input())
	numbers = input().split()
	found = False
	for i in range(2, number_of_entries):
		if int(numbers[i - 2]) < int(numbers[i - 1]) and int(numbers[i - 1]) > int(numbers[i]):
			print('YES')
			print(i - 1, i, i + 1)
			found = True
			break
	if not found:
		print('NO')


import os
import sys
from io import BytesIO, IOBase
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')
testcases = int(input())
for j in range(testcases):
	n = int(input())
	vals = list(map(int, input().split()))
	left = 0
	right = n - 1
	broke = False
	for s in range(n, 0, -1):
		indy = vals.index(s)
		if indy == left or indy == right:
			if indy == left:
				left += 1
			else:
				right -= 1
			continue
		else:
			index = [indy, indy + 1, indy + 2]
			print('YES')
			print(*index)
			broke = True
			break
	if broke == False:
		print('NO')


num = int(input())
for _ in range(num):
	n = int(input())
	p = [int(i) for i in input().split()]
	i = -1
	keep = True
	min_v = float('inf')
	min_i = -1
	while keep and i < n:
		for i in range(i + 1, n - 1):
			if p[i + 1] > p[i]:
				j = i + 1
				i = i
				break
		else:
			print('NO')
			break
		for k in range(max(j + 1, min_i), n):
			if p[k] < p[j]:
				print('YES')
				print(i + 1, j + 1, k + 1)
				keep = False
				break
			if min_v > p[k]:
				min_v = p[k]
				min_i = k


for _ in range(int(input())):
	a = int(input())
	l = [int(p) for p in input().split()]
	k = 0
	for i in range(1, len(l) - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			k = 1
			break
	if k == 0:
		print('NO')


T = int(input())
for t in range(1, T + 1):
	N = int(input())
	lst = input().split()
	for i in range(N):
		lst[i] = int(lst[i])
	ind = 0
	for i in range(1, N - 1):
		if lst[i - 1] < lst[i] and lst[i] > lst[i + 1]:
			ind = 1
			break
	if ind:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


def main():
	t = int(input())
	for _ in range(t):
		n = int(input())
		perm = [int(x) for x in input().split()]
		ans = None
		for i in range(n - 2):
			if perm[i] < perm[i + 1] and perm[i + 1] > perm[i + 2]:
				ans = (i, i + 1, i + 2)
				break
		if ans != None:
			print('YES')
			for x in ans:
				print(x + 1, end=' ')
			print()
		else:
			print('NO')
main()


for _ in range(int(input())):
	n = int(input())
	ar = [int(x) for x in input().split()]
	for i in range(n - 2):
		if ar[i + 1] > ar[i + 2] and ar[i + 1] > ar[i]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	c = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			c += 1
			s = i
	if c == 0:
		print('NO')
	else:
		print('YES')
		print(s, s + 1, s + 2)


import math, string, itertools, fractions, heapq, collections, re, array, bisect, sys, copy, functools
sys.setrecursionlimit(10 ** 7)
inf = 10 ** 20
eps = 1.0 / 10 ** 10
mod = 10 ** 9 + 7
mod2 = 998244353
dd = [(-1, 0), (0, 1), (1, 0), (0, -1)]
ddn = [(-1, 0), (-1, 1), (0, 1), (1, 1), (1, 0), (1, -1), (0, -1), (-1, -1)]

def LI():
	return list(map(int, sys.stdin.readline().split()))

def LLI():
	return [list(map(int, l.split())) for l in sys.stdin.readlines()]

def LI_():
	return [int(x) - 1 for x in sys.stdin.readline().split()]

def LF():
	return [float(x) for x in sys.stdin.readline().split()]

def LS():
	return sys.stdin.readline().split()

def I():
	return int(sys.stdin.readline())

def F():
	return float(sys.stdin.readline())

def S():
	return input()

def pf(s):
	return print(s, flush=True)

def pe(s):
	return print(str(s), file=sys.stderr)

def JA(a, sep):
	return sep.join(map(str, a))

def JAA(a, s, t):
	return s.join((t.join(map(str, b)) for b in a))

def IF(c, t, f):
	return t if c else f

def main():
	t = I()
	rr = []
	for _ in range(t):
		n = I()
		a = LI()
		i = j = k = 0
		mi = a[0]
		ma = 0
		for t in range(1, n):
			c = a[t]
			if ma > c:
				k = t
				break
			elif mi < c:
				if ma < c:
					ma = c
					j = t
			elif j == 0:
				mi = c
				i = t
		if k > 0:
			rr.append('YES')
			rr.append(JA([i + 1, j + 1, k + 1], ' '))
		else:
			rr.append('NO')
	return JA(rr, '\n')
print(main())


from math import *
z = int(input())
for q in range(z):
	n = int(input())
	l = list(map(int, input().split()))
	flag = 0
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			a = i - 1 + 1
			b = i + 1
			c = i + 1 + 1
			flag = 1
			break
	if flag == 0:
		print('NO')
	else:
		print('YES')
		print(a, end=' ')
		print(b, end=' ')
		print(c)


t = int(input())
for _ in range(t):
	n = int(input())
	parr = list(map(int, input().split()))
	(b1, b2) = (False, False)
	(i, j, k) = (-1, -1, -1)
	for x in range(len(parr) - 1):
		if parr[x] < parr[x + 1]:
			i = x
		elif i > -1 and parr[x] > parr[x + 1]:
			j = x
			k = x + 1
		if i > -1 and j > -1:
			break
	if i > -1 and j > -1:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


for repeat in range(int(input())):
	length = int(input())
	arr = [int(a) for a in input().split()]
	err = True
	for i in range(length - 2):
		if arr[i + 1] > arr[i] and arr[i + 1] > arr[i + 2]:
			print('YES', '\n', i + 1, i + 2, i + 3)
			err = False
			break
	if err:
		print('NO')


from collections import defaultdict as dc
import sys
import math
mod = 10 ** 9 + 7

def sinp():
	p = str(sys.stdin.readline())
	return p

def seive(n):
	p = [0] * (n + 1)
	for i in range(2, n):
		for j in range(2 * i, n + 1, i):
			p[i] = 1
	return p

def inp():
	p = int(sys.stdin.readline())
	return p

def line():
	p = list(map(int, sys.stdin.readline().split()))
	return p

def read_mat():
	n = inp()
	a = []
	for i in range(n):
		a.append(line())
	return a

def ind(a):
	return ord(a) - ord('A')

def digit(n):
	p = [int(i) for i in str(n)]
	return p

def check(s, k):
	for i in range(7):
		if s[i] != '?' and s[i] != k[i]:
			return 0
	return 1
t = inp()
for i in range(t):
	n = inp()
	a = line()
	p = sorted(a, reverse=True)
	q = dc(int)
	for i in range(n):
		q[a[i]] = i + 1
	x = [a[n - 1]]
	mn = a[0]
	for i in range(n - 2, -1, -1):
		x.append(min(x[-1], a[i]))
	x = x[::-1]
	l = 0
	for i in range(1, n - 1):
		mx = x[i + 1]
		if mn < a[i] > mx:
			print('YES')
			print(q[mn], i + 1, q[mx])
			l = 1
			break
		mn = min(mn, a[i])
	if l == 0:
		print('NO')


if True:
	for _ in range(int(input())):
		while True:
			break
		n = int(input())
		list1 = [int(x) for x in input().split()]
		flag = 0
		for i in range(1, len(list1) - 1):
			minLVal = min(list1[0:i])
			minRVal = min(list1[i + 1:])
			if list1[i] > minLVal and list1[i] > minRVal:
				flag = 1
				indexOne = list1.index(minLVal)
				indexThree = list1.index(minRVal)
				print('YES')
				print(indexOne + 1, i + 1, indexThree + 1)
				break
		if True:
			if flag == 0:
				print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	key = 0
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			key = 1
			break
	if key == 0:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	x = list(map(int, input().split()))
	index = -1
	for i in range(1, n - 1):
		if x[i] > x[i - 1] and x[i] > x[i + 1]:
			index = i + 1
			break
	if index == -1:
		print('NO')
	else:
		print('YES')
		print(index - 1, index, index + 1)


for _ in range(int(input())):
	n = int(input())
	li = list(map(int, input().strip().split()))
	flag = 0
	for i in range(1, n - 1):
		if li[i - 1] < li[i] and li[i + 1] < li[i]:
			flag = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if flag == 0:
		print('NO')


case = int(input())
for i in range(case):
	n = int(input())
	lst = list(map(int, input().split()))
	mi = 0
	switch = 0
	ans = False
	for i in range(1, n):
		if switch == 0:
			if lst[i] < lst[mi]:
				mi = i
			else:
				switch = 1
				ma = i
		elif lst[i] < lst[ma]:
			print('YES')
			print(mi + 1, ma + 1, i + 1)
			ans = True
			break
		else:
			ma = i
	if not ans:
		print('NO')


import math

def main():
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			return
	print('NO')
	return

def test():
	t = int(input())
	while t:
		main()
		t -= 1
test()


for _ in range(int(input())):
	n = int(input())
	lst = list(map(int, input().split()))
	valid = False
	mi = lst[0]
	mi_i = 0
	min_lst = [0] * n
	for i in range(n):
		min_lst[i] = (mi, mi_i)
		if lst[i] < mi:
			mi = lst[i]
			mi_i = i
	mx = lst[-1]
	mx_i = n - 1
	mx_lst = [0] * n
	for j in range(n - 1, -1, -1):
		mx_lst[j] = (mx, mx_i)
		if mx > lst[j]:
			mx = lst[j]
			mx_i = j
	for i in range(1, n - 1):
		if min_lst[i][0] < lst[i] and lst[i] > mx_lst[i][0]:
			valid = True
			a = min_lst[i][1] + 1
			b = i + 1
			c = mx_lst[i][1] + 1
			break
	if valid:
		print('YES')
		print(a, b, c)
	else:
		print('NO')


from sys import stdin
input = stdin.buffer.readline
for _ in range(int(input())):
	n = int(input())
	(*a,) = map(int, input().split())
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	ar = list(map(int, input().split()))
	ret = False
	for i in range(n, 2, -1):
		idx = ar.index(i)
		if idx != 0 and idx != n - 1 and (ar[idx - 1] < ar[idx]) and (ar[idx + 1] < ar[idx]):
			ret = idx + 1
			break
	if ret:
		print('YES')
		print(ret - 1, ret, ret + 1)
	else:
		print('NO')


import sys
input = sys.stdin.buffer.readline

def solution():
	for _ in range(int(input())):
		n = int(input())
		l = list(map(int, input().split()))
		flag = 0
		for i in range(1, n - 1):
			if l[i] > l[i + 1] and l[i - 1] < l[i]:
				print('YES')
				print(i, i + 1, i + 2)
				flag = 1
				break
		if flag == 0:
			print('NO')
solution()


import math, sys, bisect, heapq
from collections import defaultdict, Counter, deque
from itertools import groupby, accumulate
input = iter(sys.stdin.buffer.read().decode().splitlines()).__next__
ilele = lambda : map(int, input().split())
alele = lambda : list(map(int, input().split()))

def Y(c):
	print(['NO', 'YES'][c])

def y(c):
	print(['no', 'yes'][c])

def Yy(c):
	print(['No', 'Yes'][c])
for _ in range(int(input())):
	N = int(input())
	A = alele()
	f = 0
	for i in range(N - 2):
		x = A[i]
		y = A[i + 1]
		z = A[i + 2]
		if x < y and y > z:
			Y(1)
			f = 1
			print(i + 1, i + 2, i + 3)
			break
	if f == 0:
		Y(0)


for _ in range(int(input())):
	n = int(input())
	w = list(map(int, input().split()))
	for i in range(1, n - 1):
		if w[i - 1] < w[i] > w[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


t = int(input())
arr = []
for i in range(t):
	arr = []
	n = int(input())
	arr.append(list(map(int, input().rstrip().split())))
	arr = arr[0]
	flag = 0
	for j in range(1, n - 1):
		if arr[j - 1] < arr[j] and arr[j] > arr[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


def find(perm, n):
	dp = []
	for i in range(n):
		if not dp:
			dp.append((perm[i], i))
		elif perm[i] < dp[-1][0]:
			dp.append((perm[i], i))
		else:
			dp.append(dp[-1])
	return dp

def solve(perm, ans):
	n = len(perm)
	dpleft = find(perm, n)
	perm.reverse()
	dpright = find(perm, n)
	dpright.reverse()
	perm.reverse()
	for j in range(1, n - 1):
		curr = perm[j]
		(left, i) = dpleft[j - 1]
		(right, k) = dpright[j + 1]
		k = n - k
		i += 1
		if curr > left and curr > right:
			ans.append('YES')
			ans.append(str(i) + ' ' + str(j + 1) + ' ' + str(k))
			return
	ans.append('NO')

def main():
	t = int(input())
	ans = []
	for i in range(t):
		n = int(input())
		perm = list(map(int, input().split()))
		solve(perm, ans)
	for i in ans:
		print(i)
main()


def solve_testcase(n: int, permutation: list):
	begin = 0
	end = n - 1
	flag = False
	for i in range(n, 0, -1):
		if permutation[begin] == i:
			begin += 1
		elif permutation[end] == i:
			end -= 1
		else:
			idx = permutation.index(i)
			flag = True
			break
	if flag:
		for i in range(begin, idx + 1):
			if permutation[i] < permutation[idx]:
				a = i
				break
		for i in range(idx, end + 1):
			if permutation[i] < permutation[idx]:
				b = i
				break
		print('YES')
		print(a + 1, idx + 1, b + 1)
	else:
		print('NO')

def input_testcase():
	n = int(input())
	perm = [int(term) for term in input().split()]
	return (n, perm)
t = int(input())
for i in range(t):
	solve_testcase(*input_testcase())


import sys

def scan():
	return map(int, sys.stdin.readline().strip().split())
for ___ in range(int(input())):
	n = int(input())
	a = list(scan())
	b = 0
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			b = 1
			break
	if b == 1:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


t = int(input())
while t:
	t = t - 1
	n = int(input())
	a = list(map(int, input().split()))
	x = 0
	flag = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			flag = 1
			x = i
			break
	if flag:
		print('YES')
		print(x - 1 + 1, x + 1, x + 1 + 1)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	check = False
	for i in range(1, len(a) - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			check = True
			break
	if check == False:
		print('NO')


def solve():
	n = int(input())
	a = list(map(int, input().split()))
	x = a.copy()
	y = a.copy()
	x.sort()
	y.sort(reverse=True)
	if a == x or a == y:
		print('NO')
		return
	i = 0
	while i < n - 1 and a[i + 1] < a[i]:
		i += 1
	while i < n - 1 and a[i + 1] > a[i]:
		i += 1
	if i == n - 1:
		print('NO')
		return
	else:
		print('YES')
		print(i, i + 1, i + 2)
t = int(input())
for _ in range(t):
	solve()


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	for i in range(1, n - 1):
		if l[i - 1] < l[i] > l[i + 1]:
			f = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if f == 0:
		print('NO')


t = int(input())
for z in range(t):
	n = int(input())
	nums = [int(x) for x in input().split()]
	flag = 1
	for i in range(1, n - 1):
		if nums[i] > nums[i - 1] and nums[i] > nums[i + 1]:
			print('YES')
			print(str(i) + ' ' + str(i + 1) + ' ' + str(i + 2))
			flag = 0
			break
	if flag != 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	l = [[arr[0], 0]]
	r = [[arr[n - 1], n - 1]]
	for i in range(1, n - 2):
		if l[i - 1][0] < arr[i]:
			l.append([l[i - 1][0], l[i - 1][1]])
		else:
			l.append([arr[i], i])
	for i in range(n - 2, 1, -1):
		if r[i + 1 - n + 1][0] < arr[i]:
			r.append([r[i + 1 - n + 1][0], r[i + 1 - n + 1][1]])
		else:
			r.append([arr[i], i])
	f = 0
	r.reverse()
	for i in range(1, n - 1):
		if l[i - 1][0] < arr[i] and r[i - 1][0] < arr[i]:
			x = l[i - 1][1] + 1
			y = i + 1
			z = r[i - 1][1] + 1
			f = 1
			break
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(x, y, z)


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2, sep=' ')
			break
		elif i == n - 2:
			print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	b = False
	for i in range(1, n - 1):
		if b:
			break
		l = min(a[:i])
		r = min(a[i + 1:])
		if l < a[i] and r < a[i]:
			print('YES')
			print(a.index(l) + 1, i + 1, len(a) - a[::-1].index(r))
			b = True
	if not b:
		print('NO')


for t in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	isFound = False
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			isFound = True
			res = (i, i + 1, i + 2)
			break
	if isFound:
		print('YES')
		print(*res)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	small = False
	big = False
	s = a[0]
	ans = [1]
	for i in range(1, n):
		if not small and (not big):
			if a[i] > s:
				s = a[i]
				small = True
				ans.append(i + 1)
			else:
				s = a[i]
				ans[0] = i + 1
		elif small and (not big):
			if a[i] < s:
				big = True
				ans.append(i + 1)
			else:
				s = a[i]
				ans[1] = i + 1
		else:
			break
	if small and big:
		print('YES')
		print(ans[0], ans[1], ans[2])
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	flag = 0
	for j in range(len(l) - 1):
		if j + 2 > len(l) - 1:
			break
		if l[j] < l[j + 1] and l[j + 1] > l[j + 2]:
			x = j
			flag = 1
	if flag == 0:
		print('NO')
	else:
		print('YES')
		print(x + 1, x + 2, x + 3)


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	Fin = False
	for i in range(n - 1):
		if l[i] < l[i + 1]:
			break
		if i == n - 2:
			Fin = True
			print('No')
	for j in range(i, n - 1):
		if Fin:
			break
		if l[j] > l[j + 1]:
			Fin = True
			print('Yes')
			print(j, j + 1, j + 2)
			break
	if not Fin:
		print('No')


def solution():
	n = int(input())
	(el_prev_2, el_prev_1) = (10 ** 9 + 2, 10 ** 9 + 1)
	i = 0
	for el in input().split():
		el = int(el)
		if el_prev_2 < el_prev_1 > el:
			return 'YES\n' + str(i - 1) + ' ' + str(i) + ' ' + str(i + 1)
		(el_prev_2, el_prev_1) = (el_prev_1, el)
		i += 1
	return 'NO'
for test_i in range(int(input())):
	print(solution())


for t in range(int(input())):
	n = int(input())
	p = [int(x) for x in input().split()]
	if n == 3:
		if p[1] > p[0] and p[1] > p[2]:
			print('YES')
			print(1, 2, 3)
		else:
			print('NO')
	else:
		found = False
		for i in range(n - 2):
			x = p[i + 1] - p[i]
			y = p[i + 2] - p[i + 1]
			if x > 0 and y < 0:
				print('YES')
				print(i + 1, i + 2, i + 3)
				found = True
				break
		if not found:
			print('NO')


import math
import datetime
for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


for w in range(int(input())):
	n = int(input())
	arr = list(map(int, input().strip().split()))
	i = 1
	while i < n and arr[i] < arr[i - 1]:
		i += 1
	k = i + 1
	while k < n and arr[k] > arr[k - 1]:
		k += 1
	j = k
	if j >= n:
		print('NO')
	else:
		while j < n and arr[j] > arr[k]:
			j += 1
		if j == n:
			print('NO')
		else:
			print('YES')
			print(i, k, j + 1)


t = int(input())
for _ in range(t):
	n = int(input())
	list1 = list(map(int, input().strip().split()))
	b = 0
	for i in range(1, n - 1):
		if list1[i] > list1[i - 1] and list1[i] > list1[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			b = 1
			break
	if b == 0:
		print('NO')


cases = int(input())
for x in range(cases):
	listLen = int(input())
	perm = list(map(int, input().split()))
	oneIndex = perm.index(1)
	found = False
	for y in range(oneIndex + 1, listLen - 1):
		if perm[y] > perm[y + 1]:
			print('YES')
			print(oneIndex + 1, y + 1, y + 2)
			found = True
			break
	if not found:
		for y in range(0, oneIndex - 1):
			if perm[y] < perm[y + 1]:
				print('YES')
				print(y + 1, y + 2, oneIndex + 1)
				found = True
				break
	if not found:
		print('NO')


t = int(input())
for test in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	found = False
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			found = True
			break
	if found != True:
		print('NO')


import sys
import math
import itertools
import functools
import collections
import operator
import fileinput
import copy
ORDA = 97

def ii():
	return int(input())

def mi():
	return map(int, input().split())

def li():
	return [int(i) for i in input().split()]

def lcm(a, b):
	return abs(a * b) // math.gcd(a, b)

def revn(n):
	return str(n)[::-1]

def dd():
	return collections.defaultdict(int)

def ddl():
	return collections.defaultdict(list)

def sieve(n):
	if n < 2:
		return list()
	prime = [True for _ in range(n + 1)]
	p = 3
	while p * p <= n:
		if prime[p]:
			for i in range(p * 2, n + 1, p):
				prime[i] = False
		p += 2
	r = [2]
	for p in range(3, n + 1, 2):
		if prime[p]:
			r.append(p)
	return r

def divs(n, start=2):
	r = []
	for i in range(start, int(math.sqrt(n) + 1)):
		if n % i == 0:
			if n / i == i:
				r.append(i)
			else:
				r.extend([i, n // i])
	return r

def divn(n, primes):
	divs_number = 1
	for i in primes:
		if n == 1:
			return divs_number
		t = 1
		while n % i == 0:
			t += 1
			n //= i
		divs_number *= t

def prime(n):
	if n == 2:
		return True
	if n % 2 == 0 or n <= 1:
		return False
	sqr = int(math.sqrt(n)) + 1
	for d in range(3, sqr, 2):
		if n % d == 0:
			return False
	return True

def convn(number, base):
	newnumber = 0
	while number > 0:
		newnumber += number % base
		number //= base
	return newnumber

def cdiv(n, k):
	return n // k + (n % k != 0)

def ispal(s):
	for i in range(len(s) // 2 + 1):
		if s[i] != s[-i - 1]:
			return False
	return True
for _ in range(ii()):
	n = ii()
	p = li()
	for i in range(1, n - 1):
		if p[i - 1] < p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	lst = list(map(int, input().split()))
	end = False
	for i in range(1, n - 1):
		if lst[i - 1] < lst[i] and lst[i] > lst[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			end = True
			break
	if not end:
		print('NO')


import sys
input = sys.stdin.readline
from collections import deque
t = int(input())
for tests in range(t):
	n = int(input())
	P = list(map(int, input().split()))
	Q = deque(P)
	NOW = n
	while NOW:
		if Q[0] == NOW:
			Q.popleft()
			NOW -= 1
		elif Q[-1] == NOW:
			Q.pop()
			NOW -= 1
		else:
			break
	if NOW == 0:
		print('NO')
	else:
		print('YES')
		ANS = P.index(NOW)
		print(ANS, ANS + 1, ANS + 2)


def find_ans(arr, n):
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	find_ans(arr, n)


import io
import os
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
from sys import stdout

def solve():
	n = int(input())
	a = list(map(int, input().split()))
	flag = 1
	for i in range(n):
		flag = 1
		ma = a[i]
		c = [i + 1, 0, 0]
		stack = []
		for j in range(i + 1, n):
			if flag == 2:
				if a[stack[-1]] > a[j]:
					c[1] = stack[-1] + 1
					c[2] = j + 1
					flag = 3
					break
			if a[j] > ma:
				stack.append(j)
				flag = 2
		if flag == 3:
			stdout.write('YES\n')
			print(*c)
			break
	if flag != 3:
		stdout.write('NO\n')

def main():
	for t in range(int(input())):
		solve()
main()


def run():
	t = int(input())
	for T in range(t):
		n = int(input())
		nums = list(map(int, input().split()))
		ans = False
		for i in range(1, n - 1):
			val = nums[i]
			x = i
			y = -1
			z = -1
			for j in range(i):
				if nums[j] < val:
					y = j
					break
			if y != -1:
				for k in range(i + 1, n):
					if nums[k] < val:
						z = k
						ans = True
						break
			if ans:
				break
		if ans:
			print('YES')
			print(f'{y + 1} {x + 1} {z + 1}')
		else:
			print('NO')
run()


from sys import stdin
input = lambda : stdin.readline().rstrip('\r\n')
from collections import deque as que
from collections import defaultdict as vector
from heapq import *
inin = lambda : int(input())
inar = lambda : list(map(int, input().split()))

def SOLVEA():
	n = inin()
	a = inar()
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')

def SOLVEB():
	s = input()
	ans = []
	for i in s:
		if i == 'R':
			ans.append('P')
		if i == 'P':
			ans.append('S')
		if i == 'S':
			ans.append('R')
	print(''.join(ans))
Testcase = inin()
for _ in range(Testcase):
	SOLVEA()


try:
	for _ in range(int(input())):
		n = int(input())
		arr = [int(x) for x in input().split()]
		j = 1
		ns = 0
		flag = 0
		k = 2
		for i in range(n - 2):
			if i < j and j < k:
				if arr[i] < arr[j] and arr[j] > arr[k]:
					flag = 1
					ns = i
					break
				j += 1
				k += 1
		if flag == 1:
			print('YES')
			print(str(ns + 1) + ' ' + str(j + 1) + ' ' + str(k + 1))
		else:
			print('NO')
except:
	pass


t = int(input())
for j in range(t):
	count = 0
	n = int(input())
	lst = list(map(int, input().split()))
	for i in range(n - 2):
		if lst[i] < lst[i + 1] > lst[i + 2]:
			print('Yes')
			print(i + 1, i + 2, i + 3)
			count = 1
			break
	if count == 0:
		print('No')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	i = 0
	j = n - 1
	k = None
	m = n
	while j - i >= 2:
		if l[i] == m or l[j] == m:
			if l[i] == m:
				i = i + 1
				m = m - 1
			else:
				j = j - 1
				m = m - 1
		else:
			k = l.index(m)
			break
	if k:
		print('YES')
		print(i + 1, k + 1, j + 1)
	else:
		print('NO')


t = int(input())
bl = list()
for i in range(t):
	n = int(input())
	s = str(input()).split()
	l = []
	for k in s:
		l.append(int(k))
	bl.append(l)
for z in bl:
	f = 0
	for i in range(1, len(z) - 1):
		if z[i] > z[i - 1]:
			if z[i] > z[i + 1]:
				f = 1
				print('YES')
				print(i, i + 1, i + 2)
				break
	if f == 0:
		print('NO')


import os
import sys
from io import BytesIO, IOBase

def solution(arr, n):
	(r1, r2) = (-1, -1)
	for j in range(1, n - 1):
		for i in range(j):
			if arr[i] < arr[j]:
				r1 = i
				break
		for k in range(j + 1, n):
			if arr[j] > arr[k]:
				r2 = k
				break
		if r1 != -1 and r2 != -1:
			write('YES')
			write(r1 + 1, j + 1, r2 + 1)
			return
		(r1, r2) = (-1, -1)
	write('NO')

def main():
	for _ in range(r_int()):
		n = r_int()
		arr = r_array()
		solution(arr, n)
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))

def input():
	return sys.stdin.readline().rstrip('\r\n')

def write(*args, end='\n'):
	for x in args[:-1]:
		sys.stdout.write(str(x) + ' ')
	sys.stdout.write(str(args[-1]))
	sys.stdout.write(end)

def r_array():
	return [int(x) for x in input().split()]

def r_int():
	return int(input())
main()


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	a = 0
	b = 0
	(ans1, ans2, ans3) = (0, 0, 0)
	i = 0
	for i in range(1, n):
		if p[i] > p[i - 1] and (not a):
			a = 1
			ans1 = i
			ans2 = i + 1
		elif p[i] > p[i - 1] and a:
			ans2 = i + 1
		elif a:
			ans3 = i + 1
			b = 1
		if a and b:
			break
	if a and b:
		print('YES')
		print(ans1, ' ', ans2, ' ', ans3)
	else:
		print('NO')


def Bump(Arr, n):
	temp = [False, False]
	indices = [0, 0, 0]
	for i in range(n - 1):
		if Arr[i] < Arr[i + 1] and temp[0] == False:
			temp[0] = True
		elif Arr[i] > Arr[i + 1] and temp[0] == True:
			temp[1] = True
			indices = [i, i + 1, i + 2]
			break
	if temp == [True, True]:
		print('YES')
		print(*indices)
	else:
		print('NO')

def Run(t):
	test = []
	for i in range(t):
		temp = [int(input()), [int(i) for i in input().split()]]
		test.append(temp)
	for i in range(t):
		Bump(test[i][1], test[i][0])
Run(int(input()))


import math
t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().strip().split()))
	i = 0
	j = 0
	k = 0
	h = 1
	while h < n:
		if arr[h] < arr[h - 1]:
			i = h
			h = h + 1
		else:
			break
	if h >= n - 1:
		print('NO')
	else:
		j = h
		r = j + 1
		while r < n:
			if arr[r] < arr[j]:
				k = r
				break
			else:
				j = r
				r = r + 1
		if k == 0:
			print('NO')
		else:
			print('YES')
			print(i + 1, j + 1, k + 1)


for i in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	ans = 0
	for j in range(1, n - 1):
		if l[j - 1] < l[j] and l[j] > l[j + 1]:
			ans = 1
			print('YES')
			print(j, j + 1, j + 2)
			break
	if ans == 0:
		print('NO')


import sys
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	n = int(input())
	p = [int(_) for _ in input().split()]
	pp = [0] * (n - 1)
	ans = None
	for i in range(n - 1):
		if p[i] < p[i + 1]:
			pp[i] = 1
		else:
			pp[i] = -1
	for i in range(n - 2):
		if pp[i] == 1 and pp[i + 1] == -1:
			ans = [i + 1, i + 2, i + 3]
			break
	if ans:
		print('YES')
		print(*ans)
	else:
		print('NO')


from sys import stdin, stdout
from collections import Counter
from itertools import permutations
import bisect
import math
I = lambda : map(int, stdin.readline().split())
I1 = lambda : stdin.readline()

def unique(sequence):
	seen = set()
	return [x for x in sequence if not (x in seen or seen.add(x))]
for _ in range(int(I1())):
	n = int(I1())
	l = list(I())
	f = 0
	for i in range(1, n - 1):
		b = l[i]
		a = c = b
		for j in range(i):
			if a > l[j]:
				a = l[j]
				i1 = j
		for j in range(i + 1, n):
			if c > l[j]:
				c = l[j]
				i2 = j
		if a < b and b > c:
			f = 1
			print('Yes')
			print(i1 + 1, i + 1, i2 + 1)
			break
	if f == 0:
		print('No')


for t in range(int(input())):
	n = int(input())
	ara = list(map(int, input().split()))
	c = 0
	for i in range(1, n - 1):
		if ara[i] > ara[i + 1] and ara[i] > ara[i - 1]:
			c = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if c == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = [int(i) for i in input().split()]
	ans = 0
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			ans = i + 1
	if ans > 0:
		print('YES')
		print(ans - 1, ans, ans + 1)
	else:
		print('NO')


from sys import stdin, stdout
import sys
INF = 100000000000.0
import bisect

def get_int():
	return int(stdin.readline().strip())

def get_ints():
	return map(int, stdin.readline().strip().split())

def get_array():
	return list(map(int, stdin.readline().strip().split()))

def get_string():
	return stdin.readline().strip()

def op(c):
	return stdout.write(c)
from collections import defaultdict
import math
for t in range(int(stdin.readline())):
	n = get_int()
	arr = get_array()
	(x, y, z) = (-1, -1, -1)
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			(x, y, z) = (i - 1, i, i + 1)
			break
	if x != -1:
		print('YES')
		print(x + 1, y + 1, z + 1)
	else:
		print('NO')


def main():
	for _ in range(int(input())):
		n = int(input())
		lst = list(map(int, input().split()))
		ans = -1
		for i in range(1, n - 1, 1):
			if lst[i - 1] < lst[i] and lst[i] > lst[i + 1]:
				print('YES\n{} {} {}'.format(i, i + 1, i + 2))
				break
		else:
			print('NO')
main()


from sys import stdin, stdout
from collections import Counter
from math import ceil
from bisect import bisect_left
from bisect import bisect_right
import math

def ai():
	return list(map(int, stdin.readline().split()))

def ei():
	return map(int, stdin.readline().split())

def ip():
	return int(stdin.readline().strip())

def op(ans):
	return stdout.write(str(ans) + '\n')
for i in range(ip()):
	n = ip()
	li = ai()
	f = 1
	for i in range(1, n - 1):
		if li[i - 1] < li[i] and li[i] > li[i + 1]:
			f = 0
			print('YES')
			print(i - 1 + 1, i + 1, i + 1 + 1)
			break
	if f == 1:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	fl = True
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			print('Yes')
			print(i + 1, i + 2, i + 3)
			fl = False
			break
	if fl:
		print('No')


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	permutation = False
	for a in range(1, n - 1):
		if p[a] > p[a - 1] and p[a] > p[a + 1]:
			i = a - 1
			j = a
			k = a + 1
			permutation = True
	if permutation == True:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


import sys
input = lambda : sys.stdin.readline().rstrip()
for _ in range(int(input())):
	n = int(input())
	a = [int(i) - 1 for i in input().split()]
	flag = 0
	for i in range(n - 2):
		k = i
		while k < n - 1 and a[k] <= a[i]:
			k += 1
		maxx = a[k]
		ind = k
		for j in range(k + 1, n):
			if a[j] < maxx:
				print('YES')
				print(i + 1, ind + 1, j + 1)
				flag = 1
				break
			else:
				maxx = a[j]
				ind = j
		if flag == 1:
			break
	if flag == 0:
		print('NO')


def solve(n, lst):
	for i in range(1, n - 1):
		if lst[i - 1] < lst[i] and lst[i] > lst[i + 1]:
			return ' '.join(map(str, [i, i + 1, i + 2]))
	return 'NO'
for _ in range(int(input())):
	n = int(input())
	lst = list(map(int, input().split()))
	s = solve(n, lst)
	if s == 'NO':
		print(s)
	else:
		print('YES')
		print(s)


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	min = [0, l[0]]
	max = [0, 0]
	for i in range(1, n):
		if max[1] == 0:
			if l[i] < min[1]:
				min = [i, l[i]]
			else:
				max = [i, l[i]]
		elif l[i] < max[1]:
			print('YES')
			print(min[0] + 1, max[0] + 1, i + 1)
			n = 0
			break
		else:
			max = [i, l[i]]
	if n > 0:
		print('NO')


def function(N):
	for i in range(1, N - 1):
		if lineup[i] > lineup[i - 1] and lineup[i] > lineup[i + 1]:
			return [i, i + 1, i + 2]
	return 0
for i in range(int(input())):
	N = int(input())
	lineup = [int(x) for x in input().split()]
	if function(N) != 0:
		print('YES')
		print(*function(N))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	p1 = 1001
	a1 = -1
	a2 = -1
	a3 = -1
	p = 0
	for i in range(n):
		if a[i] <= p1 and p == 0:
			a1 = i + 1
			p1 = a[i]
		if p1 < a[i]:
			p = 1
			a2 = i + 1
			p1 = a[i]
		if p1 > a[i] and p == 1:
			a3 = i + 1
			break
	if a1 == -1 or a2 == -1 or a3 == -1:
		print('NO')
	else:
		print('YES')
		print(a1, a2, a3)


for _ in range(int(input())):
	a = int(input())
	b = [int(i) for i in input().split()]
	c = False
	for i in range(1, a - 1):
		if b[i] > b[i - 1] and b[i] > b[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			c = True
			break
	if not c:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	left = [0] * n
	right = [0] * n
	left[0] = l[0]
	i = 1
	while i < n and l[i] < l[i - 1]:
		i += 1
	if i is n:
		print('No')
	else:
		i -= 1
		j = i + 1
		while j < n and l[j] > l[j - 1]:
			j += 1
		if j is n:
			print('No')
		else:
			print('Yes')
			print(i + 1, j, j + 1)


for _ in range(int(input())):
	a = int(input())
	b = [int(i) for i in input().split()]
	x2 = 0
	for i in range(1, a - 1):
		if max(b[i], b[i - 1], b[i + 1]) == b[i]:
			x2 = i
			break
	if x2 != 0:
		print('YES')
		print(x2, x2 + 1, x2 + 2)
	else:
		print('NO')


from sys import stdin, stdout
from math import gcd, ceil, sqrt
from collections import Counter
from bisect import bisect_left, bisect_right
ii1 = lambda : int(stdin.readline().strip())
is1 = lambda : stdin.readline().strip()
iia = lambda : list(map(int, stdin.readline().strip().split()))
isa = lambda : stdin.readline().strip().split()
mod = 1000000007
tc = ii1()
for _ in range(tc):
	n = ii1()
	arr = iia()
	for i in range(n):
		cur = arr[i]
		sml = big = None
		for j in range(i):
			if arr[j] < cur:
				sml = j
		for j in range(i + 1, n):
			if arr[j] < cur:
				big = j
		if sml != None and big != None:
			print('Yes')
			print(sml + 1, i + 1, big + 1)
			break
	else:
		print('No')


t = int(input())
for i in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	ans = 'NO'
	a = 0
	(x, y, z) = (0, 0, 0)
	for j in range(n - 1):
		if l[j] < l[j + 1]:
			a = 1
			x = j + 1
			y = j + 2
		if l[j] > l[j + 1]:
			if a == 1:
				ans = 'YES'
				y = j + 1
				z = j + 2
				break
	print(ans)
	if ans == 'YES':
		print(x, y, z)


from collections import defaultdict
import sys, math
f = None
try:
	f = open('q1.input', 'r')
except IOError:
	f = sys.stdin
if 'xrange' in dir(__builtins__):
	range = xrange
sys.setrecursionlimit(10 ** 2)

def print_case_iterable(case_num, iterable):
	print('Case #{}: {}'.format(case_num, ' '.join(map(str, iterable))))

def print_case_number(case_num, iterable):
	print('Case #{}: {}'.format(case_num, iterable))

def print_iterable(A):
	print(' '.join(A))

def read_int():
	return int(f.readline().strip())

def read_int_array():
	return [int(x) for x in f.readline().strip().split(' ')]

def rns():
	a = [x for x in f.readline().split(' ')]
	return (int(a[0]), a[1].strip())

def read_string():
	return list(f.readline().strip())

def ri():
	return int(f.readline().strip())

def ria():
	return [int(x) for x in f.readline().strip().split(' ')]

def rns():
	a = [x for x in f.readline().split(' ')]
	return (int(a[0]), a[1].strip())

def rs():
	return list(f.readline().strip())

def bi(x):
	return bin(x)[2:]
from collections import deque
import math
NUMBER = 10 ** 9 + 7

def factorial(n):
	M = NUMBER
	f = 1
	for i in range(1, n + 1):
		f = f * i % M
	return f

def mult(a, b):
	return a * b % NUMBER

def minus(a, b):
	return (a - b) % NUMBER

def plus(a, b):
	return (a + b) % NUMBER

def egcd(a, b):
	if a == 0:
		return (b, 0, 1)
	else:
		(g, y, x) = egcd(b % a, a)
		return (g, x - b // a * y, y)

def modinv(a):
	m = NUMBER
	(g, x, y) = egcd(a, m)
	if g != 1:
		raise Exception('modular inverse does not exist')
	else:
		return x % m

def choose(n, k):
	if n < k:
		assert false
	return mult(factorial(n), modinv(mult(factorial(k), factorial(n - k)))) % NUMBER
from collections import deque, defaultdict
import heapq
from types import GeneratorType

def bootstrap(f, stack=[]):

	def wrappedfunc(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		else:
			to = f(*args, **kwargs)
			while True:
				if type(to) is GeneratorType:
					stack.append(to)
					to = next(to)
				else:
					stack.pop()
					if not stack:
						break
					to = stack[-1].send(to)
			return to
	return wrappedfunc

def dfs(g, timeIn, timeOut, depths, parents):
	cnt = 0
	stack = [[1, 0, 0, 0]]
	while stack:
		(v, neig_i, parent, depth) = stack[-1]
		parents[v] = parent
		depths[v] = depth
		if neig_i == 0:
			timeIn[v] = cnt
			cnt += 1
		while neig_i < len(g[v]):
			u = g[v][neig_i]
			if u == parent:
				neig_i += 1
				continue
			stack[-1][1] = neig_i + 1
			stack.append([u, 0, v, depth + 1])
			break
		if neig_i == len(g[v]):
			stack.pop()
			timeOut[v] = cnt
			cnt += 1
cnt = 0

@bootstrap
def dfs(v, adj, timeIn, timeOut, depths, parents, parent=0, depth=0):
	global cnt
	parents[v] = parent
	depths[v] = depth
	timeIn[v] = cnt
	cnt += 1
	for u in adj[v]:
		if u == parent:
			continue
		yield dfs(u, adj, timeIn, timeOut, depths, parents, v, depth + 1)
	timeOut[v] = cnt
	cnt += 1
	yield

def gcd(a, b):
	if a == 0:
		return b
	return gcd(b % a, a)

def lcm(a, b):
	return a * b / gcd(a, b)

def get_num_2_5(n):
	twos = 0
	fives = 0
	while n > 0 and n % 2 == 0:
		n //= 2
		twos += 1
	while n > 0 and n % 5 == 0:
		n //= 5
		fives += 1
	return (twos, fives)

def shift(a, i, num):
	for _ in range(num):
		(a[i], a[i + 1], a[i + 2]) = (a[i + 2], a[i], a[i + 1])

def equal(x, y):
	return abs(x - y) <= 1e-09

def getAngle(a, b, c):
	ang = math.degrees(math.atan2(c[1] - b[1], c[0] - b[0]) - math.atan2(a[1] - b[1], a[0] - b[0]))
	return ang + 360 if ang < 0 else ang

def getLength(a, b):
	return math.sqrt((a[0] - b[0]) ** 2 + (a[1] - b[1]) ** 2)
from heapq import heapify, heappush, heappop

def solution(a, n):
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			return 'YES' + '\n' + f'{i} {i + 1} {i + 2}'
	return 'NO'

def main():
	T = 1
	T = ri()
	for i in range(T):
		n = ri()
		a = ria()
		x = solution(a, n)
		if 'xrange' not in dir(__builtins__):
			print(x)
		else:
			(print >> output, str(x))
	if 'xrange' in dir(__builtins__):
		print(output.getvalue())
		output.close()
if 'xrange' in dir(__builtins__):
	import cStringIO
	output = cStringIO.StringIO()
main()


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	p = b = c = 0
	x = a[0]
	y = -1
	z = -1
	for i in range(n):
		if a[i] <= x and y == -1:
			x = a[i]
			p = i
		elif a[i] >= y and z == -1:
			y = a[i]
			b = i
		elif a[i] < y:
			c = i
			break
	if y == -1 or c == 0:
		print('NO')
	else:
		print('YES')
		print('{} {} {}'.format(p + 1, b + 1, c + 1))


class Ruiseki_lr:

	def __init__(self, array, op, e):
		self.op = op
		self.e = e
		n = len(array)
		self.left = [e] * (n + 1)
		self.right = [e] * (n + 1)
		for i in range(n):
			self.left[i + 1] = self.op(self.left[i], array[i])
		for i in reversed(range(n)):
			self.right[i] = self.op(self.right[i + 1], array[i])

	def get_left(self, p):
		return self.left[p]

	def get_right(self, p):
		return self.right[p]

	def fold(self, p):
		return self.op(self.left[p], self.right[p + 1])
t = int(input())
INF = 10 ** 9 + 7
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	ru = Ruiseki_lr(a, min, INF)
	for i in range(n):
		if ru.get_left(i) < a[i] and a[i] > ru.get_right(i + 1):
			l = 0
			l_min = INF
			for j in range(i):
				if a[j] < l_min:
					l = j
					l_min = a[j]
			r = 0
			r_min = INF
			for j in range(i + 1, n):
				if a[j] < r_min:
					r = j
					r_min = a[j]
			print('YES')
			print(l + 1, i + 1, r + 1)
			break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	m1 = [0]
	for i in range(1, n):
		if a[i] < a[m1[-1]]:
			m1.append(i)
		else:
			m1.append(m1[-1])
	m2 = [0] * n
	m2[-1] = n - 1
	for i in range(n - 2, -1, -1):
		if a[i] < a[m2[i + 1]]:
			m2[i] = i
		else:
			m2[i] = i + 1
	tf = False
	for i in range(1, n - 1):
		if a[m1[i]] < a[i] and a[m2[i]] < a[i]:
			tf = True
			ans = [m1[i] + 1, i + 1, m2[i] + 1]
			break
	if tf:
		print('YES')
		print(*ans)
	else:
		print('NO')


import bisect
t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	l2 = [[l[i], i] for i in range(n)]
	l2.sort()
	x = []
	x.append(l2[0][1])
	x.append(l2[1][1])
	x.sort()
	check = True
	for i in range(2, n):
		y = l2[i][1]
		ind = bisect.bisect_left(x, y)
		if ind != 0 and ind != len(x):
			print('YES')
			check = False
			print(x[0] + 1, y + 1, x[-1] + 1)
			break
		else:
			x.insert(ind, y)
	if check:
		print('NO')


from sys import stdin
input = stdin.readline
T = int(input())
for case in range(T):
	n = int(input())
	perm = [*map(int, input().split())]
	flag = False
	for i in range(1, n - 1):
		if perm[i - 1] < perm[i] and perm[i] > perm[i + 1]:
			flag = True
			break
	if flag:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	x = [int(x) for x in input().split()]
	t = []
	f = 1
	for i in range(1, len(x) - 1):
		if x[i] > x[i - 1] and x[i + 1] < x[i]:
			print('yes')
			print(i, i + 1, i + 2)
			f = 0
			break
	if f:
		print('no')


import sys
import os
import math
import copy
from math import gcd
from bisect import bisect
from io import BytesIO, IOBase
from math import sqrt, floor, factorial, gcd, log, ceil
from collections import deque, Counter, defaultdict
from itertools import permutations, combinations
import itertools

def Int():
	return int(sys.stdin.readline())

def Mint():
	return map(int, sys.stdin.readline().split())

def Lstr():
	return list(sys.stdin.readline().strip())

def Str():
	return sys.stdin.readline().strip()

def Mstr():
	return map(str, sys.stdin.readline().strip().split())

def List():
	return list(map(int, sys.stdin.readline().split()))

def Hash():
	return dict()

def Mod():
	return 1000000007

def Ncr(n, r, p):
	return fact[n] * (ifact[r] * ifact[n - r] % p) % p

def Most_frequent(list):
	return max(set(list), key=list.count)

def Mat2x2(n):
	return [List() for _ in range(n)]

def Lcm(x, y):
	lcm = x * y // gcd(x, y)
	return lcm

def solution():
	for i in range(Int()):
		n = Int()
		p = List()
		ans = p[0]
		k = 0
		l = []
		for i in range(1, n):
			if ans < p[i]:
				for j in range(i + 1, n):
					if p[i] > p[j]:
						l.append([k + 1, i + 1, j + 1])
					else:
						break
			else:
				ans = p[i]
				k = i
		if len(l) >= 1:
			print('YES')
			print(*l[0])
		else:
			print('NO')
solution()


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	m = n
	cc = 0
	ans = 'NO'
	while m != 2:
		i = l.index(m)
		if i == len(l) - 1:
			l.pop()
		elif i == 0:
			l.pop(0)
			cc += 1
		else:
			ans = 'YES'
			print('YES')
			print(i + cc, i + 1 + cc, i + 2 + cc)
			break
		m -= 1
	if ans != 'YES':
		print(ans)


for j in range(int(input())):
	n = input()
	f = True
	l = list(map(int, input().split()))
	for i in range(len(l) - 2):
		if l[i] < l[i + 1] and l[i + 1] > l[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			f = False
			break
	if f:
		print('NO')


from collections import Counter
from collections import OrderedDict

def SOCountR(mylist):
	return OrderedDict(sorted(Counter(mylist).items(), reverse=True))

def SOCount(mylist):
	return OrderedDict(sorted(Counter(mylist).items()))

def freq_count(mylist):
	return Counter(mylist)
t = int(input())
for _ in range(t):
	n = int(input())
	arr = [int(x) for x in input().split()]
	if n <= 1:
		print('NO')
		continue
	(i, j, k) = (0, 1, 2)
	for _ in range(2, n):
		if arr[j] > arr[i] and arr[j] > arr[k]:
			print('YES')
			print(1 + i, 1 + j, 1 + k)
			break
		i += 1
		j += 1
		k += 1
	else:
		print('NO')


T = int(input())
for _ in range(T):
	n = int(input())
	p = list(map(int, input().split()))
	sta = 0
	mid = 1
	cnt = 0
	tr = 0
	mids = [0, 0]
	for i in range(1, n):
		if cnt == 1:
			if p[i] < mids[0]:
				tr = 1
				print('YES')
				print(sta + 1, mids[1] + 1, i + 1)
				break
		if p[i] > p[sta]:
			cnt = 1
			mids[0] = max(mids[0], p[i])
			if p[i] >= mids[0]:
				mids[1] = i
		else:
			sta = i
		if i == n - 1 and tr == 0:
			print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = [int(c) for c in input().split()]
	a = [i for i in range(1, n + 1)]
	b = a[:]
	b.reverse()
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


tests = int(input())
for t in range(tests):
	n = int(input())
	ls = list(map(int, input().split()))
	high = ls[1]
	high_idx = 1
	low = ls[0]
	low_idx = 0
	res = []
	if low > high:
		low = high
		low_idx = high_idx
		high = None
	for idx in range(2, len(ls)):
		curr = ls[idx]
		if high is None:
			if curr > low:
				high = curr
				high_idx = idx
			else:
				low = curr
				low_idx = idx
		elif curr > high:
			high = curr
			high_idx = idx
		else:
			res = [low_idx + 1, high_idx + 1, idx + 1]
			break
	if res:
		print('YES')
		print(' '.join(list(map(str, res))))
	else:
		print('NO')


import sys
input = sys.stdin.readline
import heapq
import copy
import math
import decimal

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def insr2():
	s = input()
	return s[:len(s) - 1]

def invr():
	return map(int, input().split())

def pr_list(a):
	print(*a, sep=' ')

def main():
	tests = inp()
	mod = 1000000007
	limit = 10 ** 18
	ans = 0
	stack = []
	hashm = {}
	arr = []
	heapq.heapify(arr)
	for test in range(tests):
		n = inp()
		a = inlt()
		smallest = [n - 1]
		for i in range(n - 1, -1, -1):
			if a[i] < a[smallest[-1]]:
				smallest.append(i)
			else:
				smallest.append(smallest[-1])
		smallest.reverse()
		mini = 0
		flag = 0
		for i in range(1, n - 1):
			if a[mini] < a[i] and a[i] > a[smallest[i + 1]]:
				print('YES')
				pr_list([mini + 1, i + 1, smallest[i + 1] + 1])
				flag = 1
				break
			elif a[i] < a[mini]:
				mini = i
		if flag == 0:
			print('NO')
main()


t = int(input())
while t:
	t -= 1
	n = int(input())
	lis = list(map(int, input().split(' ')))
	(n1, n2, n3) = (-1, -1, -1)
	for x in range(len(lis)):
		n1 = x
		togg = 1
		for y in range(len(lis)):
			if y > n1:
				if togg == 1:
					if lis[y] > lis[n1]:
						n2 = y
						togg = 0
				elif lis[y] < lis[n2] and y > n2:
					n3 = y
					togg = -1
		if togg == -1:
			break
	if -1 in (n1, n2, n3):
		print('NO')
	else:
		print('YES')
		print(n1 + 1, n2 + 1, n3 + 1)


import sys
input = sys.stdin.readline
t = int(input())
for i in range(t):
	n = int(input())
	p = [int(i) for i in input().split() if i != '\n']
	(left, right, mid) = (p[0], 0, p[-1])
	(ind1, ind2, ind3) = (1, 0, n)
	ok2 = False
	for i in range(n):
		if ok2 == False:
			if p[i] > left:
				ok2 = True
				mid = p[i]
				ind2 = i + 1
			else:
				left = p[i]
				ind1 = i + 1
		if ok2 == True:
			if p[i] < mid:
				ind3 = i + 1
				print('YES')
				print(ind1, ind2, ind3)
				break
			else:
				mid = p[i]
				ind2 = i + 1
	else:
		print('NO')


def solve(n, a):
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
t = int(input())
for h in range(t):
	n = int(input())
	a = [int(x) for x in input().split(' ')]
	solve(n, a)


import sys
import heapq
import collections

def main():
	t = int(input())
	for _ in range(t):
		n = int(input())
		nums = list(map(int, sys.stdin.readline().split()))
		ans = None
		for i in range(n - 2):
			if nums[i] < nums[i + 1] and nums[i + 1] > nums[i + 2]:
				ans = [i + 1, i + 2, i + 3]
		if ans:
			print('YES')
			for i in ans:
				print(i, end=' ')
			print('')
		else:
			print('NO')
	return
main()


import sys, os, io

def rs():
	return sys.stdin.readline().rstrip()

def ri():
	return int(sys.stdin.readline())

def ria():
	return list(map(int, sys.stdin.readline().split()))

def ws(s):
	sys.stdout.write(s + '\n')

def wi(n):
	sys.stdout.write(str(n) + '\n')

def wia(a):
	sys.stdout.write(' '.join([str(x) for x in a]) + '\n')
import math, datetime, functools
from collections import deque, defaultdict, OrderedDict
import collections

def main():
	starttime = datetime.datetime.now()
	if os.path.exists('input.txt'):
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	for _ in range(ri()):
		t = 0
		n = ri()
		a = ria()
		for i in range(1, n - 1):
			if a[i] > a[i - 1] and a[i] > a[i + 1]:
				ws('YES')
				print(i, i + 1, i + 2)
				t = 1
				break
		if t == 0:
			ws('NO')
	endtime = datetime.datetime.now()
	time = (endtime - starttime).total_seconds() * 1000
	if os.path.exists('input.txt'):
		print('Time:', time, 'ms')

class FastReader(io.IOBase):
	newlines = 0

	def __init__(self, fd, chunk_size=1024 * 8):
		self._fd = fd
		self._chunk_size = chunk_size
		self.buffer = io.BytesIO()

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, self._chunk_size))
			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, size=-1):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, self._chunk_size if size == -1 else size))
			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()

class FastWriter(io.IOBase):

	def __init__(self, fd):
		self._fd = fd
		self.buffer = io.BytesIO()
		self.write = self.buffer.write

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

class FastStdin(io.IOBase):

	def __init__(self, fd=0):
		self.buffer = FastReader(fd)
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

class FastStdout(io.IOBase):

	def __init__(self, fd=1):
		self.buffer = FastWriter(fd)
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.flush = self.buffer.flush
sys.stdin = FastStdin()
sys.stdout = FastStdout()
main()


t = int(input())
while t:
	t -= 1
	n = int(input())
	lis = list(map(int, input().split()))
	g = 0
	for i in range(1, n - 1):
		if lis[i - 1] < lis[i] > lis[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			g = 1
			break
	if not g:
		print('NO')


for i in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	(r, t) = (a.index(n), 1)
	for j in range(1, n - 1):
		if a[j - 1] < a[j] and a[j] > a[j + 1]:
			print('YES', '\n', j, j + 1, j + 2)
			t = 0
			break
	if t:
		print('NO')


import sys
lines = []
for line in sys.stdin:
	if 'exit' == line.rstrip().lower():
		break
	lines.append(line)
t = int(lines[0])
for case in range(1, 2 * t + 1, 2):
	n = int(lines[case])
	p = [int(x) for x in lines[case + 1].split(' ')]
	right = [-1] * n
	left = [-1] * n
	g = p[n - 1]
	g_i = n - 1
	for i in range(n - 1, -1, -1):
		if g < p[i]:
			right[i] = g_i
		else:
			g = p[i]
			g_i = i
	l = p[0]
	l_i = 0
	for i in range(0, n, 1):
		if l < p[i]:
			left[i] = l_i
		else:
			l = p[i]
			l_i = i
	found = False
	for i in range(n):
		if right[i] != -1 and left[i] != -1:
			print('YES')
			print(str(left[i] + 1) + ' ' + str(i + 1) + ' ' + str(right[i] + 1))
			found = True
			break
	if not found:
		print('NO')


import math

def sumofno(n):
	summ = 0
	while n > 0:
		summ += n % 10
		n //= 10
	return summ

def get_key(val, lis):
	for (key, value) in lis.items():
		if value == val:
			return key
try:
	t = int(input())
	ans = []
	for i in range(t):
		n = int(input())
		a = list(map(int, input().split()))
		com = 0
		flag = 0
		for j in range(n - 2):
			if a[j] < a[j + 1] and a[j + 1] > a[j + 2]:
				ans.append('YES')
				ans.append(str(j + 1) + ' ' + str(j + 2) + ' ' + str(j + 3))
				flag = 1
				break
		if flag == 0:
			ans.append('NO')
	for an in ans:
		print(an)
except:
	pass


for i in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	flag = 0
	l1 = l.copy()
	l1.sort()
	l1.reverse()
	for j in range(len(l)):
		a = l.index(l1[j])
		b = 0
		c = 0
		if a == 0 or a == len(l) - 1:
			continue
		else:
			for k in range(a):
				if l[k] < l[a]:
					b = k
					break
			for k in range(a + 1, len(l)):
				if l[k] < l[a]:
					c = k
					break
			if c > 0 and l[b] < l[a]:
				flag = 1
				print('YES')
				print(b + 1, a + 1, c + 1)
				break
	if flag == 0:
		print('NO')


t = int(input())
while t > 0:
	t -= 1
	n = int(input())
	a = list(map(int, input().split()))
	maxx = 0
	maxi = -1
	q = False
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			q = True
			break
		else:
			q = False
	if q == False:
		print('NO')


import sys
input = sys.stdin.readline

def solve(N, A):
	Ind = [-1] * (N + 1)
	for (i, a) in enumerate(A):
		Ind[a] = i
	minind = N + 1
	maxind = -1
	for n in range(1, N + 1):
		ind = Ind[n]
		if minind < ind < maxind:
			print('YES')
			print(minind + 1, ind + 1, maxind + 1)
			return
		minind = min(minind, ind)
		maxind = max(maxind, ind)
	print('NO')
	return
Q = int(input())
for _ in range(Q):
	N = int(input())
	A = list(map(int, input().split()))
	solve(N, A)


from sys import stdin
from collections import deque
mod = 10 ** 9 + 7
import sys
import random
from queue import PriorityQueue
from collections import Counter as cc
from bisect import bisect_right
from bisect import bisect_left
from collections import defaultdict
from math import sqrt, factorial, gcd, log2, inf, ceil
import heapq
input = lambda : sys.stdin.readline().rstrip()
from sys import stdin, stdout
from heapq import heapify, heappush, heappop
from itertools import permutations
from math import factorial as f

def ncr(n, r, p):
	num = den = 1
	for i in range(r):
		num = num * (n - i) % p
		den = den * (i + 1) % p
	return num * pow(den, p - 2, p) % p
import sys
t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	pref1 = [l[0]]
	pref2 = [l[-1]]
	hash = defaultdict(int)
	for i in range(n):
		hash[l[i]] = i
	for i in range(1, n):
		pref1.append(min(pref1[-1], l[i]))
	for i in range(n - 2, -1, -1):
		pref2.append(min(pref2[-1], l[i]))
	pref2.reverse()
	(x, y, z) = (-1, -1, -1)
	for i in range(1, n - 1):
		z1 = pref1[i - 1]
		z2 = pref2[i + 1]
		if l[i] > z1 and l[i] > z2:
			(x, y, z) = (hash[z1] + 1, i + 1, hash[z2] + 1)
			break
	if x + y + z != -3:
		print('YES')
		print(x, y, z)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = [*map(int, input().split())]
	l = p.index(n)
	if 0 < l < n - 1:
		print('YES')
		print(l, l + 1, l + 2)
		continue
	for i in range(n):
		(f1, f2) = (0, 0)
		for j in range(i):
			if p[i] > p[j]:
				pos1 = j
				f1 = 1
				break
		for j in range(i + 1, n):
			if p[i] > p[j]:
				pos2 = j
				f2 = 1
				break
		if f1 and f2:
			print('YES')
			print(pos1 + 1, i + 1, pos2 + 1)
			break
	if not (f1 and f2):
		print('NO')


T = int(input())
for tc in range(T):
	N = int(input())
	flag = 0
	listi = list(map(int, input().split()))[:N]
	for i in range(N - 2):
		if listi[i] < listi[i + 1]:
			if listi[i + 1] > listi[i + 2]:
				print('YES')
				print(i + 1, i + 2, i + 3)
				flag = 1
				break
			else:
				flag = 0
		else:
			flag = 0
	if flag == 0:
		print('NO')


for _ in range(int(input())):
	T = int(input())
	a = [int(x) for x in input().split()]
	for (i, (u, w, v)) in enumerate(zip(a, a[1:], a[2:])):
		if u < w and w > v:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


t = int(input())
while t > 0:
	t = t - 1
	n = int(input())
	a = list(map(int, input().split()))
	k = 0
	for i in range(1, len(a) - 1):
		b = a[:i]
		c = a[i:]
		if a[i] > min(b) and a[i] > min(c):
			print('YES')
			print(a.index(min(b)) + 1, i + 1, a.index(min(c)) + 1)
			k = 1
			break
	if k == 0:
		print('NO')


def fast(arr):
	for i in range(len(arr) - 2):
		j = i + 1
		k = i + 2
		if arr[i] < arr[j] and arr[j] > arr[k]:
			return [i, j, k]
	return None

def main():
	t = int(input())
	for _ in range(t):
		n = int(input())
		arr = [int(x) for x in input().split()]
		result = fast(arr)
		if result:
			print('YES')
			print(' '.join((str(x + 1) for x in result)))
		else:
			print('NO')
main()


import os
import sys
from io import BytesIO, IOBase
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')

def RL():
	return map(int, sys.stdin.readline().rstrip().split())

def RLL():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def N():
	return int(input())

def comb(n, m):
	return factorial(n) / (factorial(m) * factorial(n - m)) if n >= m else 0

def perm(n, m):
	return factorial(n) // factorial(n - m) if n >= m else 0

def mdis(x1, y1, x2, y2):
	return abs(x1 - x2) + abs(y1 - y2)
mod = 998244353
INF = float('inf')
from math import factorial
from collections import Counter, defaultdict, deque
from heapq import heapify, heappop, heappush

def main():
	for _ in range(N()):
		n = N()
		arr = RLL()
		lmi = [-1] * n
		rmi = [-1] * n
		mi = INF
		ind = -1
		for i in range(n):
			if arr[i] > mi:
				lmi[i] = ind
			if arr[i] < mi:
				mi = arr[i]
				ind = i
		mi = INF
		ind = -1
		for i in range(n - 1, -1, -1):
			if arr[i] > mi:
				rmi[i] = ind
			if arr[i] < mi:
				mi = arr[i]
				ind = i
		for i in range(1, n - 1):
			if lmi[i] != -1 and rmi[i] != -1:
				print('YES')
				print(lmi[i] + 1, i + 1, rmi[i] + 1)
				break
		else:
			print('NO')
main()


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	flag = 0
	for i in range(n - 1, -1, -1):
		value = arr.index(i + 1)
		if i == n - 1 and value != i:
			if value != 0 and value != n - 1:
				if arr[value - 1] < arr[value] and arr[value] > arr[value + 1]:
					flag = 1
					print('YES')
					print(value, '', value + 1, '', value + 2)
					break
		elif value != 0 and value != n - 1:
			if arr[value - 1] < arr[value] and arr[value] > arr[value + 1]:
				flag = 1
				print('YES')
				print(value, '', value + 1, '', value + 2)
				break
	if flag == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = [int(x) for x in input().split()]
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
		elif i == n - 2:
			print('NO')


t = int(input())

def func(l):
	n = len(l)
	for i in range(n - 2):
		if l[i + 1] > l[i] and l[i + 1] > l[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			return True
	print('NO')
	return False
for a in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	func(l)


import math, sys
t = int(input())
while t != 0:
	t -= 1
	n = int(input())
	p = list(map(int, input().split()))
	c = 0
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			c = 1
			break
	if c == 1:
		continue
	print('NO')


def up(arr):
	l = []
	for i in range(len(arr)):
		for j in range(i + 1, len(arr) - 1):
			if arr[i] < arr[j] > arr[j + 1] and len(l) < 1:
				l.append([i + 1, j + 1, j + 1 + 1])
			break
	return l
t = int(input())
for i in range(t):
	n = int(input())
	arr1 = list(map(int, input().split()))
	p = up(arr1)
	if len(p) == 0:
		print('NO')
	else:
		print('YES')
		print(*p[0], sep=' ')


def find132pattern(nums):
	intervals = []
	(i, s) = (1, 0)
	while i < len(nums):
		if nums[i] < nums[i - 1]:
			if s < i - 1:
				intervals.append([nums[s], nums[i - 1]])
			s = i
		for a in intervals:
			if nums[i] > a[0] and nums[i] < a[1] or nums[i] < a[0]:
				res = [nums[i], a[0], a[1]]
				return (True, res)
		i += 1
	return (False, [])

def main():
	n = int(input())
	for i in range(n):
		t = input()
		N = [int(i) for i in input().split()]
		(b, res) = find132pattern(N)
		m = {}
		for i in range(len(N)):
			m[N[i]] = i + 1
		if b:
			print('YES')
			r = [m[res[0]], m[res[1]], m[res[2]]]
			r.sort()
			print(str(r[0]) + ' ' + str(r[1]) + ' ' + str(r[2]))
		else:
			print('NO')
main()


from collections import deque

def solve():
	n = int(input())
	(*a,) = map(int, input().split())
	ad = {ai: i for (i, ai) in enumerate(a)}
	a = deque(a)
	end = False
	for i in range(n, 0, -1):
		if a[0] != i and a[-1] != i:
			print('YES')
			print(ad[a[0]] + 1, ad[i] + 1, ad[a[-1]] + 1)
			end = True
			break
		if a[0] == i:
			a.popleft()
		else:
			a.pop()
	if not end:
		print('NO')
t = int(input())
for _ in range(t):
	solve()


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	n = int(input())
	ar = list(map(int, input().split()))
	dic = {}
	for i in range(n):
		dic[ar[i]] = i
	mi = []
	ma = []
	mmi = n
	mma = 1
	for i in range(1, n + 1):
		mmi = min(mmi, dic[i])
		mma = max(mma, dic[i])
		mi.append(mmi)
		ma.append(mma)
	flag = True
	for i in range(1, n):
		if mi[i - 1] < dic[i + 1] and ma[i - 1] > dic[i + 1]:
			print('YES')
			print(mi[i - 1] + 1, dic[i + 1] + 1, ma[i - 1] + 1)
			flag = False
			break
	if flag:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	c = 0
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i - 1 + 1, i + 1, i + 1 + 1)
			break
	else:
		print('NO')


tc = int(input())
for _ in range(tc):
	t = int(input())
	p = list(map(int, input().split()))
	pog = True
	for i in range(len(p) - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(str(i + 1) + ' ' + str(i + 2) + ' ' + str(i + 3))
			pog = False
			break
	if pog:
		print('NO')


T = int(input())
for t in range(0, T):
	n = int(input())
	a = list(map(int, input().split()))
	i = 1
	c = 0
	while i < n - 1:
		left = [l for l in a[:i] if l < a[i]]
		right = [r for r in a[i + 1:] if a[i] > r]
		if left != [] and right != []:
			c = 1
			print('YES')
			j = a.index(left[0])
			k = a.index(right[0])
			print(j + 1, i + 1, k + 1)
			break
		else:
			i = i + 1
	if c == 0:
		print('NO')


import sys
from functools import lru_cache, cmp_to_key
from heapq import merge, heapify, heappop, heappush
from collections import defaultdict as dd, deque, Counter as C
from itertools import combinations as comb, permutations as perm
from bisect import bisect_left as bl, bisect_right as br, bisect
from time import perf_counter
from fractions import Fraction
mod = int(pow(10, 9) + 7)
mod2 = 998244353

def data():
	return sys.stdin.readline().strip()

def out(*var, end='\n'):
	sys.stdout.write(' '.join(map(str, var)) + end)

def L():
	return list(sp())

def sl():
	return list(ssp())

def sp():
	return map(int, data().split())

def ssp():
	return map(str, data().split())

def l1d(n, val=0):
	return [val for i in range(n)]

def l2d(n, m, val=0):
	return [l1d(n, val) for j in range(m)]
try:
	sys.stdin = open('input.txt', 'r')
except:
	pass
t = L()[0]
for _ in range(t):
	n = L()[0]
	A = L()
	arr = []
	for j in range(1, n - 1):
		for i in range(j):
			if A[i] < A[j]:
				break
		else:
			i = j
		for k in range(n - 1, j - 1, -1):
			if A[j] > A[k]:
				break
		else:
			k = j
		if i != j and k != j:
			arr = [i + 1, j + 1, k + 1]
			break
	if arr:
		print('YES')
		print(*arr)
	else:
		print('NO')


import sys
import math as mt
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	vis = [0] * (n + 1)
	ch = 0
	(a, b, c) = (-1, -1, -1)
	pre = [0] * (n + 1)
	suf = [0] * (n + 1)
	pre[0] = l[0]
	for i in range(1, n):
		pre[i] = min(pre[i - 1], l[i])
	suf[n - 1] = l[n - 1]
	for j in range(n - 2, -1, -1):
		suf[j] = min(l[j], suf[j + 1])
	d = {}
	for i in range(n):
		d[l[i]] = i + 1
	for i in range(1, n - 1):
		if pre[i - 1] < l[i] and suf[i + 1] < l[i]:
			(a, b, c) = (d[pre[i - 1]], d[l[i]], d[suf[i + 1]])
			break
	if a != -1 and b != -1 and (c != -1):
		print('YES')
		print(a, b, c)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = [int(j) for j in input().split()]
	flag = 0
	for j in range(1, n - 1):
		if p[j] > p[j - 1] and p[j] > p[j + 1]:
			i = j + 1 - 1
			j = j + 1
			k = j + 1
			flag = 1
			break
	if flag == 1:
		print('YES\n{} {} {}'.format(i, j, k))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	ans = []
	for i in range(n, 0, -1):
		a = l.index(i)
		if a != 0 and a != n - 1:
			if l[a - 1] < l[a] and l[a + 1] < l[a]:
				ans = [a, a + 1, a + 2]
				break
	if len(ans) == 0:
		print('NO')
	else:
		print('YES')
		print(*ans)


t = int(input())

def pp():
	n = int(input())
	l = list(map(int, input().split()))
	for i in range(n - 2):
		if l[i] < l[i + 1] and l[i + 1] > l[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			return
	print('NO')
	return
while t:
	pp()
	t -= 1


t = int(input())
for i in range(t):
	n = int(input())
	lst = list(map(int, input().split()))
	flag = 0
	for j in range(1, n - 1):
		if lst[j - 1] < lst[j] and lst[j] > lst[j + 1]:
			ans = [j, j + 1, j + 2]
			flag = 1
			break
	if flag == 1:
		print('yes')
		print(*ans)
	else:
		print('NO')


import math as mt

def tran(arr):
	s = []
	for i in range(len(arr) - 2):
		if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
			s.append(i + 1)
			s.append(i + 2)
			s.append(i + 3)
			if len(s) == 3:
				break
	return s
t = int(input())
ans = []
for i in range(t):
	n = int(input())
	arr = list(map(int, input().rstrip().split()))
	r = tran(arr)
	ans.append(r)
for i in ans:
	if len(i) == 3:
		print('YES')
		print(*i)
	else:
		print('NO')


for i in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	for j in range(1, n - 1):
		if l[j] > l[j - 1] and l[j] > l[j + 1]:
			f = 1
			break
		else:
			continue
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(j, j + 1, j + 2)


t = int(input())
while t != 0:
	t = t - 1
	n = int(input())
	arr = list(map(int, input().strip().split()))[:n]
	flag = 0
	for x in range(1, n - 1):
		if arr[x] > arr[x - 1] and arr[x] > arr[x + 1]:
			print('YES')
			print(x, x + 1, x + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


def solution(x):
	for num in range(len(x)):
		if num + 2 < len(x):
			if x[num] < x[num + 1] > x[num + 2]:
				return f'Yes\n{num + 1} {num + 2} {num + 3}'
	return 'No'

def main():
	for test in range(int(input())):
		_ = input()
		p = list(map(int, input().split()))
		result = solution(p)
		print(result)
main()


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	for i in range(1, n - 1):
		jind = i
		f1 = 0
		f2 = 0
		for j in range(i - 1, -1, -1):
			if l[j] < l[i]:
				f1 = 1
				i1 = j
				break
		for j in range(i + 1, n, 1):
			if l[j] < l[i]:
				f2 = 1
				i2 = j
				break
		if f1 == 1 and f2 == 1:
			f = 1
			break
	if f == 1:
		print('YES\n', i1 + 1, jind + 1, i2 + 1)
	else:
		print('NO')


t = int(input())
for x in range(t):
	n = int(input())
	p = list(map(int, input().split(' ')))
	for j in range(1, n - 1):
		if p[j] > p[j - 1] and p[j] > p[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	ok = False
	for i in range(n):
		ab = 0
		bl = 0
		for j in range(n):
			if j < i and a[j] < a[i]:
				bl = j + 1
			if j > i and a[j] < a[i]:
				ab = j + 1
		if ab and bl:
			ok = True
			print('YES')
			print(bl, i + 1, ab)
			break
	if not ok:
		print('NO')


for i in range(int(input())):
	n = int(input())
	x = list(map(int, input().split()))
	c = 0
	for i in range(1, len(x) - 1):
		if x[i - 1] < x[i] and x[i] > x[i + 1]:
			c = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
		else:
			continue
	if c == 0:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	j = -1
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			j = i
			break
	if j == -1:
		print('NO')
	else:
		print('YES')
		print(j + 1, j + 2, j + 3)


x = int(input())
for i in range(x):
	a = int(input())
	l = list(map(int, input().split()))
	for j in range(1, len(l) - 1):
		if l[j - 1] < l[j] and l[j + 1] < l[j]:
			print('YES')
			print(j, j + 1, j + 2)
			break
	else:
		print('NO')


import os
import operator
import sys
from io import BytesIO, IOBase

def inar():
	return [int(k) for k in input().split()]

def main():
	for _ in range(int(input())):
		n = int(input())
		arr = inar()
		counter = 0
		for i in range(1, n - 1):
			if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				counter = 1
				break
		if counter == 0:
			print('NO')
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')
main()


t = int(input(''))
mat = []
for i in range(t):
	x = int(input(''))
	mat.append(list(map(int, input().split())))
for i in range(t):
	y = mat[i]
	maxx = len(y)
	if y[0] == maxx or y[len(y) - 1] == maxx:
		flag = 0
		for k in range(1, len(y) - 1, 1):
			if y[k] > y[k - 1] and y[k] > y[k + 1]:
				flag = 1
				print('YES')
				print(k, k + 1, k + 2)
				break
		if flag == 0:
			print('NO')
	else:
		print('YES')
		j = y.index(maxx) + 1
		print(j - 1, j, j + 1)


Q = int(input())
for q in range(Q):
	N = int(input())
	L = list(map(int, input().split()))
	F = [[L[0], 0]]
	for i in range(1, N):
		if L[i] < F[-1][0]:
			F.append([L[i], i])
		else:
			F.append(F[-1])
	RL = L[::-1]
	E = [[RL[0], N - 1]]
	for i in range(1, N):
		if RL[i] < E[-1][0]:
			E.append([RL[i], N - 1 - i])
		else:
			E.append(E[-1])
	E = E[::-1]
	f = 0
	for j in range(1, N - 1):
		if L[j] > F[j][0] and L[j] > E[j][0]:
			print('YES')
			print(F[j][1] + 1, j + 1, E[j][1] + 1)
			f = 1
			break
	if f == 0:
		print('NO')


num = int(input())
for _ in range(num):
	n = int(input())
	p = [int(i) for i in input().split()]
	i = -1
	keep = True
	while keep and i < n:
		for i in range(i + 1, n - 1):
			if p[i + 1] > p[i]:
				j = i + 1
				i = i
				break
		else:
			print('NO')
			break
		for k in range(j + 1, n):
			if p[k] < p[j]:
				print('YES')
				print(i + 1, j + 1, k + 1)
				keep = False
				break


import math
import sys
t = int(input())
for cs in range(t):
	n = int(input())
	a = [int(_) for _ in input().split()]
	opt = -1
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			opt = i
	if opt == -1:
		print('NO')
	else:
		print('YES')
		opt += 1
		print(opt - 1, opt, opt + 1)


T = int(input())
for z in range(T):
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


import array as arr
debug = False
T = int(input())
while T > 0:
	N = int(input())
	testArr = arr.array('i', [])
	lnArray = input().split(' ')
	mx = 0
	curEle = 0
	for i in range(0, N):
		curEle = int(lnArray[i])
		testArr.append(curEle)
		if curEle > mx:
			mx = curEle
	if debug:
		print('mx= %s' % mx)
	mnLeft = mx + 1
	mnRight = mx + 1
	mnIndLeft = -1
	mnIndRight = -1
	mnArrayLeft = arr.array('i', [])
	mnArrayRight = arr.array('i', [])
	mnArrayLeft.append(-1)
	mnArrayRight.append(-1)
	for i in range(1, N):
		if debug:
			print(testArr[i])
		curLeftEle = testArr[i - 1]
		curRightEle = testArr[N - i]
		if debug:
			print('i=%s curLeft=%s curRight=%s mnIndLeft=%s mnIndRight=%s' % (i, curLeftEle, curRightEle, mnIndLeft, mnIndRight))
		if curLeftEle < mnLeft:
			mnLeft = curLeftEle
			mnIndLeft = i - 1
		mnArrayLeft.append(mnIndLeft)
		if curRightEle < mnRight:
			mnRight = curRightEle
			mnIndRight = N - i
		mnArrayRight.append(mnIndRight)
	if debug:
		for i in range(0, len(mnArrayLeft)):
			print('%s ,' % mnArrayLeft[i], end=' ')
		print()
		for i in range(0, len(mnArrayRight)):
			print('%s ,' % mnArrayRight[i], end=' ')
		print()
	indFinalLeft = -1
	indFinalMiddle = -1
	indFinalRight = -1
	for i in range(1, N - 1):
		indFinalLeft = -1
		indFinalRight = -1
		if testArr[i] <= testArr[mnArrayLeft[i]]:
			continue
		else:
			indFinalLeft = mnArrayLeft[i]
		if testArr[i] <= testArr[mnArrayRight[N - 1 - i]]:
			continue
		else:
			indFinalRight = mnArrayRight[N - 1 - i]
		if indFinalLeft != -1 and indFinalRight != -1:
			indFinalMiddle = i
			break
	if indFinalLeft == -1 or indFinalRight == -1:
		print('NO')
	else:
		print('YES')
		print('%s %s %s' % (indFinalLeft + 1, indFinalMiddle + 1, indFinalRight + 1))
	T -= 1


t = int(input())
while t:
	n = int(input())
	l1 = list(map(int, input().split()))
	check = 0
	for i in range(1, n - 1):
		if l1[i] > l1[i - 1] and l1[i] > l1[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')
	t = t - 1


import sys
from functools import lru_cache, cmp_to_key
from heapq import merge, heapify, heappop, heappush, nsmallest
from math import ceil, floor, gcd, fabs, factorial, fmod, sqrt, inf, log
from collections import defaultdict as dd, deque, Counter as C
from itertools import combinations as comb, permutations as perm
from bisect import bisect_left as bl, bisect_right as br, bisect
from time import perf_counter
from fractions import Fraction
from decimal import Decimal
mod = pow(10, 9) + 7
mod2 = 998244353

def data():
	return sys.stdin.readline().strip()

def out(var):
	sys.stdout.write(str(var) + '\n')

def outa(*var, end='\n'):
	sys.stdout.write(' '.join(map(str, var)) + end)

def l():
	return list(sp())

def sl():
	return list(ssp())

def sp():
	return map(int, data().split())

def ssp():
	return map(str, data().split())

def l1d(n, val=0):
	return [val for i in range(n)]

def l2d(n, m, val=0):
	return [l1d(n, val) for j in range(m)]
for _ in range(int(data())):
	n = int(data())
	arr = l()
	index = dd(int)
	for i in range(n):
		index[arr[i]] = i
	r = False
	for i in range(n, 2, -1):
		(j, k) = (index[i] - 1, index[i] + 1)
		while j >= 0 and k < n:
			if arr[j] < i and arr[k] < i:
				(a, b, c) = (j, index[i], k)
				r = True
				break
			if arr[j] > i:
				j -= 1
			if arr[k] > i:
				k += 1
		if r:
			break
	if not r:
		out('NO')
		continue
	out('YES')
	outa(a + 1, b + 1, c + 1)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	minSeen = [1 << 30 for _ in range(n)]
	minSeenBack = [1 << 30 for _ in range(n)]
	for i in range(n):
		if i == 0:
			minSeen[i] = a[i]
		else:
			minSeen[i] = min(a[i], minSeen[i - 1])
	for i in range(n - 1, -1, -1):
		if i == n - 1:
			minSeenBack[i] = a[i]
		else:
			minSeenBack[i] = min(a[i], minSeenBack[i + 1])
	ans = []
	for i in range(1, n - 1):
		if minSeen[i - 1] < a[i] and a[i] > minSeenBack[i + 1]:
			for k in range(i):
				if a[k] < a[i]:
					ans.append(str(k + 1))
					break
			ans.append(str(i + 1))
			for k in range(i + 1, n):
				if a[k] < a[i]:
					ans.append(str(k + 1))
					break
			break
	if ans == []:
		print('NO')
	else:
		print('YES')
		print(' '.join(ans))


import sys
T = input()
for t in range(int(T)):
	n = input()
	pArr = input().split()
	inc = False
	dec = False
	prevP = 0
	for (idx, p) in enumerate(pArr):
		p = int(p)
		if idx == 0:
			prevP = p
			continue
		if not inc and (not dec):
			if p < prevP:
				prevP = p
				continue
		if p > prevP:
			inc = True
			prevP = p
			i = idx
			j = idx + 1
		elif inc and (not dec):
			if p < prevP:
				dec = True
				k = idx + 1
				break
	if inc and dec:
		print('yes')
		print('%i %i %i' % (i, j, k))
	else:
		print('no')


t = int(input())
for i in range(t):
	n = int(input())
	x = list(map(int, input().split()))
	count = 0
	for j in range(1, n - 1):
		if x[j] > x[j - 1] and x[j] > x[j + 1]:
			print('YES')
			print(j, end=' ')
			print(j + 1, end=' ')
			print(j + 2)
			count = 1
			break
	if count == 0:
		print('NO')


t = int(input())
for u in range(t):
	n = int(input())
	a = [int(i) for i in input().split()]
	le = [0] * n
	ri = [n - 1] * n
	for i in range(1, n - 1):
		if a[i] < a[le[i - 1]]:
			le[i] = i
		else:
			le[i] = le[i - 1]
	for i in range(n - 2, 0, -1):
		if a[i] < a[ri[i + 1]]:
			ri[i] = i
		else:
			ri[i] = ri[i + 1]
	for i in range(1, n - 1):
		if a[le[i - 1]] < a[i] > a[ri[i + 1]]:
			print('YES')
			print(le[i - 1] + 1, i + 1, ri[i + 1] + 1)
			break
	else:
		print('NO')


from math import ceil

def main():
	t = int(input())
	for i in range(t):
		n = int(input())
		values = list(map(int, input().split()))
		minimum = values[0]
		index = 0
		maximum = 0
		index_max = -1
		for i in range(1, n):
			if index_max != -1 and values[i] < maximum:
				print('YES')
				print(index + 1, index_max + 1, i + 1)
				break
			elif values[i] < minimum:
				minimum = values[i]
				index = i
			elif values[i] > maximum or index_max == -1:
				maximum = values[i]
				index_max = i
		else:
			print('NO')
main()


import sys
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	n = int(input())
	a = tuple(map(int, input().split()))
	found = False
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			found = True
			break
	if not found:
		print('NO')
		continue
	print('YES')
	print(i - 1 + 1, i + 1, i + 1 + 1)


def three_indexes(n, a):
	indexes = [-1, -1, -1]
	elements = [None, None, None]
	for i in range(len(a)):
		if not elements[0]:
			elements[0] = a[i]
			indexes[0] = i + 1
		elif not elements[1]:
			if a[i] < elements[0]:
				elements[0] = a[i]
				indexes[0] = i + 1
			elif a[i] > elements[0]:
				elements[1] = a[i]
				indexes[1] = i + 1
		elif not elements[2]:
			if a[i] > elements[1]:
				elements[1] = a[i]
				indexes[1] = i + 1
			elif a[i] < elements[1]:
				indexes[2] = i + 1
				return indexes
	return []
t = int(input())
for i in range(t):
	n = int(input())
	a = [int(i) for i in input().split()]
	indexes = three_indexes(n, a)
	if indexes:
		print('YES')
		print(*indexes)
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	boo = 0
	for i in range(2, n):
		if arr[i - 2] < arr[i - 1] and arr[i - 1] > arr[i]:
			print('YES')
			print(i - 1, i, i + 1)
			boo = 1
			break
	if boo == 0:
		print('NO')


for t in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	j = n
	a = 0
	b = n - 1
	result = 0
	position = [None] * (n + 1)
	for i in range(n):
		position[p[i]] = i
	while a < b:
		if p[a] == j:
			a += 1
			j -= 1
		elif p[b] == j:
			b -= 1
			j -= 1
		else:
			i = a
			k = b
			j = position[j]
			result = 1
			break
	if result == 1:
		print('YES')
		print(i + 1, j + 1, k + 1)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	a = 0
	p = [-1] * n
	q = [-1] * n
	for i in range(1, n):
		if l[i] > l[a]:
			p[i] = a
		else:
			a = i
	b = n - 1
	for j in range(n - 2, -1, -1):
		if l[j] > l[b]:
			q[j] = b
		else:
			b = j
	f = 0
	for i in range(n):
		if p[i] != -1 and q[i] != -1:
			f = 1
			break
	if f:
		print('YES')
		print(p[i] + 1, i + 1, q[i] + 1)
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	b = a.copy()
	for i in range(n, 0, -1):
		if i == a[0]:
			a = a[1:]
		elif i == a[-1]:
			a = a[:-1]
		else:
			idx = b.index(i)
			print('YES')
			print(idx, idx + 1, idx + 2)
			break
	if a == []:
		print('NO')


T = int(input())
for t in range(T):
	n = int(input())
	A = [int(i) for i in input().split()]
	for i in range(1, n - 1):
		if A[i] > max(A[i + 1], A[i - 1]):
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


from bisect import *
from collections import *
from itertools import *
import functools
import sys
import math
from decimal import *
from copy import *
from heapq import *
from fractions import *
getcontext().prec = 30
MAX = sys.maxsize
MAXN = 1000010
MOD = 10 ** 9 + 7
spf = [i for i in range(MAXN)]
spf[0] = spf[1] = -1

def sieve():
	for i in range(2, MAXN, 2):
		spf[i] = 2
	for i in range(3, int(MAXN ** 0.5) + 1):
		if spf[i] == i:
			for j in range(i * i, MAXN, i):
				if spf[j] == j:
					spf[j] = i

def fib(n, m):
	if n == 0:
		return [0, 1]
	else:
		(a, b) = fib(n // 2)
		c = a % m * (b % m * 2 - a % m) % m
		d = a % m * (a % m) % m + b % m * b % m % m
		if n % 2 == 0:
			return [c, d]
		else:
			return [d, c + d]

def charIN(x=' '):
	return sys.stdin.readline().strip().split(x)

def arrIN(x=' '):
	return list(map(int, sys.stdin.readline().strip().split(x)))

def ncr(n, r):
	num = den = 1
	for i in range(r):
		num = num * (n - i) % MOD
		den = den * (i + 1) % MOD
	return num * pow(den, MOD - 2, MOD) % MOD

def flush():
	return sys.stdout.flush()
for _ in range(int(input())):
	n = int(input())
	a = arrIN()
	idx = defaultdict(int)
	for i in range(n):
		idx[a[i]] = i
	for i in range(n, 0, -1):
		f = 0
		for j in range(idx[i]):
			if a[j] < i:
				f += 1
				fi = j
				break
		for j in range(idx[i] + 1, n):
			if a[j] < i:
				f += 1
				si = j
				break
		if f == 2:
			print('YES')
			print(fi + 1, idx[i] + 1, si + 1)
			break
	else:
		print('NO')


from sys import stdin, stdout
from math import gcd
from collections import defaultdict
input = stdin.readline
print = stdout.write
t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	i = 0
	answer = []
	j = None
	j2 = None
	for theta in range(1, n):
		if l[i] > l[theta]:
			i = theta
		elif l[i] < l[theta]:
			j = theta
			break
	k = n - 1
	for theta in reversed(range(n)):
		if l[theta] > l[k]:
			j2 = theta
			break
		elif l[theta] < l[k]:
			k = theta
	if j == None or j2 == None or j > j2:
		print(str('NO') + '\n')
	elif l[j] >= l[j2]:
		print('YES\n' + str(i + 1) + ' ' + str(j + 1) + ' ' + str(k + 1) + '\n')
	else:
		print('YES\n' + str(i + 1) + ' ' + str(j2 + 1) + ' ' + str(k + 1) + '\n')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	flag = 0
	for i in range(1, n + 1):
		b = a.copy()
		for j in range(n):
			b[j] = b[j] - i
		neg1 = -1
		neg2 = -1
		zero = -1
		for j in range(n):
			if zero >= 0 and b[j] < 0:
				neg2 = j
			if zero < 0 and b[j] < 0:
				neg1 = j
			if b[j] == 0:
				zero = j
		if neg1 >= 0 and neg2 >= 0:
			flag = 1
			print('YES')
			print(neg1 + 1, zero + 1, neg2 + 1)
			break
	if flag == 0:
		print('NO')


import os
os_input = os.read(0, int(10000000.0)).split()
os_input_pos = -1
answer_list = []

def read_s():
	global os_input_pos
	os_input_pos += 1
	return os_input[os_input_pos].decode()

def read_i():
	return int(read_s())

def write_s(v):
	answer_list.append(v)

def write_i(v):
	write_s(str(v))

def print_ans():
	os.write(1, '\n'.join(answer_list).encode())
	os.write(1, '\n'.encode())
from types import GeneratorType

def iterative(f, stack=[]):

	def wrapped_func(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		to = f(*args, **kwargs)
		while True:
			if type(to) is GeneratorType:
				stack.append(to)
				to = next(to)
			else:
				stack.pop()
				if not stack:
					break
				to = stack[-1].send(to)
		return to
	return wrapped_func
T = read_i()
while T:
	T -= 1
	n = read_i()
	a = [read_i() for i in range(n)]
	for i in range(n):
		left = -1
		right = -1
		for j in range(n):
			if j < i and a[j] < a[i]:
				left = j
			elif j > i and a[j] < a[i]:
				right = j
		if left != -1 and right != -1:
			write_s('YES')
			write_s('{} {} {}'.format(left + 1, i + 1, right + 1))
			break
	else:
		write_s('NO')
print_ans()


t = int(input())
for x in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	for i in range(1, n - 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


n = int(input())
ans = []
for _ in range(n):
	l = int(input())
	arr = list(map(int, input().split()))
	(start, end) = (0, l - 1)
	for num in range(l, 0, -1):
		idx = arr.index(num)
		if idx == start:
			start += 1
		elif idx == end:
			end -= 1
		else:
			ans.append('YES')
			ans.append(str(idx) + ' ' + str(idx + 1) + ' ' + str(idx + 2))
			break
	else:
		ans.append('NO')
print('\n'.join(ans))


import copy
t = int(input())
while t:
	t -= 1
	n = int(input())
	a = list(map(int, input().split()))
	ok = False
	ai = 0
	aj = 0
	ak = 0
	mmax = n
	l = 0
	r = n - 1
	for y in range(n - 1):
		for i in range(n):
			if a[i] == mmax:
				if i != r and i != l:
					aj = i
					ai = i - 1
					ak = i + 1
					ok = True
					break
				else:
					if i == r:
						r -= 1
						mmax -= 1
						break
					if i == l:
						l += 1
						mmax -= 1
						break
		if ok:
			break
	if ok:
		print('YES')
		print('%d %d %d' % (ai + 1, aj + 1, ak + 1))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = [int(i) for i in input().split()]
	ans = []
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			ans = [i - 1, i, i + 1]
	if len(ans) > 0:
		print('YES')
		for x in ans:
			print(x + 1, end=' ')
		print()
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	flag = 0
	a = []
	a = [int(i) for i in input().split()]
	j = 1
	while j < n - 1:
		if a[j] > a[j - 1] and a[j] > a[j + 1]:
			print('YES')
			flag = 1
			print(j, j + 1, j + 2, end='\n')
			break
		else:
			j = j + 1
	if flag == 0:
		print('NO')


z = input
mod = 10 ** 9 + 7
from collections import *
from queue import *
from sys import *
from collections import *
from math import *
from heapq import *
from itertools import *
from bisect import *
from collections import Counter as cc
from math import factorial as f

def lcd(xnum1, xnum2):
	return xnum1 * xnum2 // gcd(xnum1, xnum2)
for _ in range(int(z())):
	n = int(z())
	l = list(map(int, z().split()))
	(a, b) = (0, 0)
	for i in range(1, n - 1):
		c = 0
		x = l[i]
		for j in range(i):
			if x > l[j]:
				a = j
				c += 1
				break
		for j in range(n - 1, i, -1):
			if x > l[j]:
				b = j
				c += 1
				break
		if c == 2:
			print('YES')
			print(a + 1, i + 1, b + 1)
			break
	else:
		print('NO')


for u in range(int(input())):
	n = int(input())
	s = list(map(int, input().split()))
	out = []
	for i in range(1, n - 1):
		if s[i] > s[i - 1] and s[i] > s[i + 1]:
			out = [i, i + 1, i + 2]
			break
	if out == []:
		print('NO')
	else:
		print('YES')
		print(out[0], out[1], out[2])


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	l1 = l.copy()
	l1.sort()
	if l == l1 or l == reversed(l1):
		print('NO')
		continue
	f = 0
	i1 = 0
	i2 = -1
	i3 = -1
	for i in range(1, n):
		if i2 == -1:
			if l[i] > l[i1]:
				i2 = i
			else:
				i1 = i
		elif i3 == -1:
			if l[i] < l[i2]:
				i3 = i
			else:
				i2 = i
		elif l[i1] < l[i2] and l[i2] > l[i3]:
			print('YES')
			print(i1 + 1, i2 + 1, i3 + 1)
			f = 1
			break
	if f == 1:
		continue
	if i2 != -1 and i3 != -1:
		if l[i1] < l[i2] and l[i2] > l[i3]:
			print('YES')
			print(i1 + 1, i2 + 1, i3 + 1)
		else:
			print('NO')
	else:
		print('NO')


from collections import defaultdict as dd
import sys
input = sys.stdin.readline
t = int(input())
while t:
	n = int(input())
	l = list(map(int, input().split()))
	mil = [0]
	for i in range(1, n):
		if l[i] < l[mil[-1]]:
			mil.append(i)
		else:
			mil.append(mil[-1])
	mir = [n - 1]
	for i in range(n - 2, -1, -1):
		if l[i] < l[mir[-1]]:
			mir.append(i)
		else:
			mir.append(mir[-1])
	lol = 0
	mir.reverse()
	for i in range(n):
		if mil[i] < i and mir[i] > i:
			print('YES')
			print(mil[i] + 1, i + 1, mir[i] + 1)
			lol = 1
			break
	if lol == 0:
		print('NO')
	t -= 1


import math
t = int(input())
for _ in range(t):
	n = int(input())
	arr = [int(i) for i in input().split()]
	ind_j = ind_k = -1
	ind_i = 0
	val_j = val_k = 0
	val_i = arr[0]
	flag1 = flag2 = flag = 0
	for i in range(1, n):
		if flag1 == 0 and arr[i] > val_i:
			val_j = arr[i]
			ind_j = i
			flag1 = 1
		elif flag1 == 0 and arr[i] < val_i:
			val_i = arr[i]
			ind_i = i
		elif flag1 == 1 and flag2 == 0 and (arr[i] > val_j):
			val_j = arr[i]
			ind_j = i
		elif flag1 == 1 and flag2 == 0 and (arr[i] < val_j):
			ind_k = i
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(ind_i + 1, ind_j + 1, ind_k + 1)
	else:
		print('NO')


def Test(String):
	List = String.split(' ')
	Found = False
	for i in range(len(List)):
		List[i] = int(List[i])
	for i in range(1, len(List) - 1):
		if List[i] > List[i - 1] and List[i] > List[i + 1]:
			Found = True
			Index = i + 1
			break
	if Found == True:
		print('YES')
		print(str(Index - 1) + ' ' + str(Index) + ' ' + str(Index + 1))
	else:
		print('NO')
trials = int(input(''))
for i in range(trials):
	input('')
	String = input('')
	Test(String)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	res = 'Null'
	for i in range(n, 2, -1):
		ax = a.index(i)
		if ax != 0 and ax != n - 1:
			if a[ax - 1] < i and a[ax + 1] < i:
				print('YES')
				print(ax, ax + 1, ax + 2)
				res = None
				break
	if res != None:
		print('NO')


def hello(arr):
	ans = []
	for i in range(n - 2):
		if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
			print('YES')
			ans.append(i + 1)
			ans.append(i + 2)
			ans.append(i + 3)
			return ans
	return ans
for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split(' ')))
	res = hello(arr)
	if len(res):
		for i in range(len(res)):
			print(res[i], end=' ')
		print()
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	s = list(map(int, input().split()))
	check = False
	for i in range(1, n - 1):
		if s[i] > s[i - 1] and s[i] > s[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			check = True
			break
	if not check:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	t = 0
	l = list(map(int, input().split()))
	for i in range(1, n - 1):
		p1 = l[i - 1]
		p2 = l[i]
		p3 = l[i + 1]
		if p1 < p2 and p2 > p3:
			t = 1
			print('YES')
			print(i, i + 1, i + 2, sep=' ')
			break
	if t == 0:
		print('NO')


import sys
import math
import collections
import operator as op
from collections import deque
from math import gcd, inf, sqrt, pi, cos, sin, ceil, log2
from bisect import bisect_right, bisect_left
from functools import reduce
from sys import stdin, stdout, setrecursionlimit
setrecursionlimit(2 ** 20)

def factorial(n):
	if n == 0:
		return 1
	return n * factorial(n - 1)

def ncr(n, r):
	r = min(r, n - r)
	numer = reduce(op.mul, range(n, n - r, -1), 1)
	denom = reduce(op.mul, range(1, r + 1), 1)
	return numer // denom

def prime_factors(n):
	i = 2
	factors = []
	while i * i <= n:
		if n % i:
			i += 1
		else:
			n //= i
			factors.append(i)
	if n > 1:
		factors.append(n)
	return len(set(factors))

def isPowerOfTwo(x):
	return x and (not x & x - 1)

def factors(n):
	return list(set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0))))

def printAllSubstrings(s, n):
	l = {}
	for i in range(n):
		temp = ''
		for j in range(i, n):
			temp += s[j]
			if temp not in l:
				l[temp] = 0
			l[temp] += 1
	return l
MOD = 1000000007
PMOD = 998244353
T = 1
T = int(stdin.readline())
for _ in range(T):
	n = int(stdin.readline())
	a = list(map(int, stdin.readline().rstrip().split()))
	k = 0
	for i in range(1, n - 1):
		if a[i] > a[i + 1] and a[i] > a[i - 1]:
			k = 1
			break
	if k == 0:
		print('NO')
	else:
		print('YES')
		print(i, i + 1, i + 2)


t = int(input())
for _ in range(t):
	n = int(input())
	mas = [int(i) for i in input().split()]
	index_mas = [0] * (n + 1)
	min = 1
	max = n
	for i in range(len(mas)):
		index_mas[mas[i]] = i + 1
	i = n
	while i > 0:
		if index_mas[i] == min:
			min += 1
		elif index_mas[i] == max:
			max -= 1
		elif min < index_mas[i] and max > index_mas[i]:
			print('YES')
			print(min, index_mas[i], max)
			i = -1
		i -= 1
	if i == 0:
		print('NO')


a = int(input())
for i in range(0, a):
	b = int(input())
	arr = list(map(int, input().split()))
	(l, m, n) = (0, 0, 0)
	for i in range(0, len(arr) - 2):
		if arr[i + 1] > arr[i] and arr[i + 1] > arr[i + 2]:
			l = i + 1
			m = i + 2
			n = i + 3
			break
	if l == 0 and m == 0 and (n == 0):
		print('NO')
	else:
		print('YES')
		print(l, m, n)


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	in1 = 0
	in2 = 0
	for i in range(1, n):
		if in2 != 0:
			if p[i] < p[in2]:
				print('YES')
				print(in1 + 1, in2 + 1, i + 1)
				break
		if p[i] > p[in1]:
			in2 = i
		else:
			in1 = i
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	x = 2
	ans = []
	flag = 0
	while x < n:
		if arr[x - 2] < arr[x - 1] and arr[x - 1] > arr[x]:
			ans = [x - 2, x - 1, x]
			flag = 1
			break
		x += 1
	if flag:
		print('YES')
		print(ans[0] + 1, ans[1] + 1, ans[2] + 1)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	for temp in range(n - 2):
		count = 0
		if l[temp + 1] > l[temp] and l[temp + 2] < l[temp + 1]:
			print('YES')
			print(temp + 1, temp + 2, temp + 3)
			count = 1
			break
	if count == 0:
		print('NO')


import sys

def read():
	return [int(i) for i in sys.stdin.readline().strip().split()]
for i in range(int(input())):
	n = int(input())
	arr = read()
	a1 = [n + 1] * n
	a2 = [n + 1] * n
	c_min = n + 1
	c_max = n + 1
	for j in range(n):
		c_min = min(c_min, arr[j])
		c_max = min(c_max, arr[~j])
		a1[j] = c_min
		a2[~j] = c_max
	done = 0
	for j in range(1, n - 1):
		if a1[j - 1] < arr[j] > a2[j + 1]:
			print('YES')
			print(arr.index(a1[j - 1]) + 1, j + 1, arr.index(a2[j + 1]) + 1)
			done = 1
			break
	if not done:
		print('NO')


t = int(input())
while t > 0:
	n = int(input())
	arr = list(map(int, input().split()))
	(i, j, k) = (-1, -1, -1)
	for I in range(1, n - 1):
		(L, R) = (I - 1, I + 1)
		while L >= 0:
			if arr[L] < arr[I]:
				i = L + 1
				break
			L -= 1
		while R < n:
			if arr[R] < arr[I]:
				k = R + 1
				break
			R += 1
		if i != -1 and k != -1:
			j = I + 1
			break
		i = -1
		k = -1
	if i == -1 or j == -1 or k == -1:
		print('NO')
	else:
		print('YES')
		print(i, j, k)
	t -= 1


import sys
input = lambda : sys.stdin.readline().rstrip()
for _ in range(int(input())):
	n = int(input())
	a = [int(x) for x in input().split()]
	(b, c) = ([], [0] * n)
	st = []
	for i in range(n):
		while st and a[st[-1]] > a[i]:
			st.pop()
		b.append(st[-1] if len(st) else -1)
		st.append(i)
	st = []
	for i in range(n - 1, -1, -1):
		while st and a[st[-1]] > a[i]:
			st.pop()
		c[i] = st[-1] if len(st) else -1
		st.append(i)
	f = False
	for i in range(n):
		if b[i] != -1 and c[i] != -1:
			f = True
			print('YES')
			print(b[i] + 1, i + 1, c[i] + 1)
			break
	if not f:
		print('NO')


from collections import Counter, defaultdict, deque
import sys
input = sys.stdin.readline

def solve():
	n = int(input())
	arr = [int(x) for x in input().split()]
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] > arr[i + 1]:
			print('yes')
			print(i, i + 1, i + 2)
			return
	print('no')
tt = int(input())
for test in range(tt):
	solve()


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	k = 0
	p = False
	q = False
	z = []
	for x in range(n - 1):
		if l[x] < l[x + 1] and p == False:
			z.append(x + 1)
			p = True
			q = True
		if l[x] > l[x + 1] and q == True:
			z.append(x + 1)
			z.append(x + 2)
			break
	if len(z) == 3:
		print('YES')
		print(*z)
	else:
		print('NO')


q = int(input())

def solve():
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(n - 1):
		mx = a[i + 1]
		mx_idx = i + 1
		for j in range(i + 1, n):
			if a[i] < mx > a[j]:
				print('YES')
				print(i + 1, mx_idx + 1, j + 1)
				return
			if a[j] > mx:
				mx = a[j]
				mx_idx = j
	print('NO')
for test in range(q):
	solve()


t = int(input())
for x in range(t):
	t1 = int(input())
	numbers = list(map(int, input().split()))
	copy_list = []
	for number in numbers:
		copy_list.append(number)
	while True:
		n = max(copy_list)
		left = numbers[:numbers.index(n)]
		right = numbers[numbers.index(n) + 1:]
		if left and right:
			min_left = min(left)
			min_right = min(right)
			if min_left < n and min_right < n:
				print('YES')
				print(numbers.index(min_left) + 1, numbers.index(n) + 1, numbers.index(min_right) + 1)
				break
		copy_list.remove(n)
		if len(copy_list) < 3:
			print('NO')
			break


t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split(' ')))
	sl = []
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			sl.append(i)
			sl.append(i + 1)
			sl.append(i + 2)
			break
	if sl:
		print('YES')
		for i in range(3):
			print(sl[i], end=' ')
		print()
	else:
		print('NO')


T = int(input())
for case in range(T):
	n = int(input())
	value = input().split()
	value = [int(val) for val in value]
	(v_p_l, v_p_r) = ([i for i in range(n)], [i for i in range(n)])
	v_p_l[0] = [value[0], 0]
	v_p_r[-1] = [value[-1], n - 1]
	decide = False
	ans = []
	for i in range(1, n):
		if value[i] < v_p_l[i - 1][0]:
			v_p_l[i] = [value[i], i]
		else:
			v_p_l[i] = v_p_l[i - 1]
	for j in range(-2, -n - 1, -1):
		if value[j] < v_p_r[j + 1][0]:
			v_p_r[j] = [value[j], n + j]
		else:
			v_p_r[j] = v_p_r[j + 1]
	for i in range(1, n - 1):
		if v_p_l[i - 1][0] < value[i] and value[i] > v_p_r[i + 1][0]:
			decide = True
			ans = [v + 1 for v in [v_p_l[i - 1][1], i, v_p_r[i + 1][1]]]
			break
	if decide is False:
		print('NO')
	else:
		print('YES')
		print('%d %d %d' % (ans[0], ans[1], ans[2]))


def solve(permu):
	i = 1
	length = len(permu)
	while i < length - 1:
		if permu[i] > permu[i - 1] and permu[i + 1] < permu[i]:
			return str(i) + ' ' + str(i + 1) + ' ' + str(i + 2)
		i += 1
	return None
t = int(input())
res = list()
for i in range(t):
	n = int(input())
	result = solve(list(map(int, input().strip().split()))[:n])
	if result == None:
		res.append('NO')
	else:
		res += ['YES', result]
for i in res:
	print(i)


def stdin(t):
	for _ in range(t):
		n = int(input())
		a = [int(x) for x in input().split()]
		print(main(n, a))

def main(n, a):
	for i in range(2, n):
		if a[i - 1] > a[i] and a[i - 1] > a[i - 2]:
			return 'YES\n{} {} {}'.format(i - 1, i, i + 1)
	return 'NO'
stdin(int(input()))


def mi():
	return map(int, input().split())

def ii():
	return int(input())

def li():
	return list(map(int, input().split()))

def si():
	return input().split()
t = ii()
for _ in range(t):
	n = ii()
	a = li()
	ind = [0 for i in range(n + 1)]
	for i in range(n):
		ind[a[i]] = i + 1
	mi = [a[0]]
	ma = [0 for i in range(n)]
	ma[-1] = a[-1]
	for i in range(1, n):
		mi.append(min(mi[-1], a[i]))
		ma[n - 1 - i] = min(a[n - 1 - i], ma[n - i])
	for i in range(1, n - 1):
		if mi[i - 1] < a[i] and a[i] > ma[i + 1]:
			print('YES')
			print(ind[mi[i - 1]], ind[a[i]], ind[ma[i + 1]])
			break
	else:
		print('NO')


def f(P, n, j):
	if n <= 2:
		return -1
	for i in range(n):
		if P[i] == n:
			break
	if i > 0 and i < n - 1:
		return [j, i + j, n - 1 + j]
	elif i == 0:
		P = P[1:]
		return f(P, n - 1, j + 1)
	elif i == n - 1:
		P = P[0:n - 1]
		return f(P, n - 1, j)
t = int(input())
while t > 0:
	t = t - 1
	n = int(input())
	p = input()
	P = list(map(int, list(p.split())))
	if f(P, n, 0) == -1:
		print('NO')
	else:
		l = f(P, n, 0)
		print('YES')
		print(l[0] + 1, end=' ')
		print(l[1] + 1, end=' ')
		print(l[2] + 1)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	for (i, (u, v, w)) in enumerate(zip(a, a[1:], a[2:])):
		if u < v > w:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


for i in range(int(input())):
	n = int(input())
	perm = list(map(int, input().split()))
	count = 0
	l = []
	for k in range(n - 1):
		if k + 2 > n - 1:
			break
		if perm[k] < perm[k + 1] and perm[k + 1] > perm[k + 2]:
			l.append(k + 1)
			l.append(k + 2)
			l.append(k + 3)
			break
		else:
			pass
	if not l:
		print('NO')
	else:
		print('YES')
		l = [str(e) for e in l]
		print(' '.join(l))


T = int(input())
for _ in range(T):
	n = int(input())
	ls = list(map(int, input().split()))
	ans = 'NO'
	for i in range(1, n - 1):
		if ls[i] > ls[i - 1] and ls[i] > ls[i + 1]:
			ans = 'YES'
			break
	if ans == 'NO':
		print(ans)
	else:
		i += 1
		print(ans)
		print(i - 1, i, i + 1)


import sys

def solve(a):
	n = len(a)
	(mn_l, mn_r) = ([0] * n, [n - 1] * n)
	for i in range(1, n):
		mn_l[i] = i if a[i] < a[mn_l[i - 1]] else mn_l[i - 1]
	for i in range(n - 2, -1, -1):
		mn_r[i] = i if a[i] < a[mn_r[i + 1]] else mn_r[i + 1]
	found = False
	for i in range(1, n - 1):
		if a[i] > a[mn_l[i]] and a[i] > a[mn_r[i]]:
			found = (mn_l[i] + 1, i + 1, mn_r[i] + 1)
			break
	print('NO' if found == False else 'YES\n' + ' '.join([str(x) for x in found]))
IN = [x.strip() for x in sys.stdin.readlines()]
T = int(IN[0])
cur = 1
for ti in range(T):
	a = [int(x) for x in IN[cur + 1].split(' ')]
	solve(a)
	cur += 2


def find_ind(n, L):
	m = max(L)
	x = L.index(m)
	var = 0
	for i in range(1, n - 1):
		if L[i] > L[i - 1]:
			if L[i] > L[i + 1]:
				k = i
				var = 1
				break
	if var == 0:
		print('NO')
	else:
		print('YES')
		print(k, k + 1, k + 2)
t = int(input())
for _ in range(t):
	n = int(input())
	L = list(map(int, input().split()))
	find_ind(n, L)


def indices(arr):
	i = 1
	while i + 1 < len(arr):
		if arr[i - 1] < arr[i] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
		i += 1
	print('NO')
	return
t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().rstrip().split()))
	indices(arr)


from math import *
for u in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	m = inf
	x = inf
	(a, b) = ([], [])
	for i in range(n):
		m = min(m, l[i])
		a.append(m)
	for i in range(n - 1, -1, -1):
		x = min(x, l[i])
		b.append(x)
	b = b[::-1]
	f = 0
	for i in range(1, n - 1):
		if l[i] > a[i] and l[i] > b[i]:
			f = 1
			x = l.index(a[i]) + 1
			z = l.index(b[i]) + 1
			y = i + 1
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(x, y, z)


t = int(input())
for i in range(t):
	n = int(input())
	l = [int(x) for x in input().split()]
	g = l.copy()
	g.sort()
	g.reverse()
	j = 0
	dog = 0
	while j <= n - 3:
		a = l.index(g[j])
		if a != 0 and a != n - 1:
			lef = -1
			ri = -1
			for k in range(a):
				if l[k] < g[j]:
					lef = k
					break
			temp = l[a + 1:]
			for k in range(n - a - 1):
				if temp[k] < g[j]:
					ri = k + 1 + a
					break
			if lef != -1 and ri != -1:
				print('YES')
				print(lef + 1, a + 1, ri + 1)
				dog = 1
				break
		j = j + 1
	if dog == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = [int(i) for i in input().split()]
	m = max(a)
	y = a.index(m)
	if y != n - 1 and y != 0:
		print('YES')
		for i in range(1, n - 1):
			if a[i] == m:
				print(i, i + 1, i + 2)
				continue
	else:
		p = -1
		q = -1
		r = -1
		for i in range(1, n - 1):
			if a[i - 1] < a[i] and a[i] > a[i + 1]:
				p = i - 1
				q = i
				r = i + 1
				break
		if p != -1 and q != -1 and (r != -1):
			print('YES')
			print(p + 1, q + 1, r + 1)
		else:
			print('NO')


for t in range(int(input())):
	n = int(input())
	s = list(map(int, input().split()))
	flag = False
	for i in range(1, len(s) - 1):
		if s[i - 1] < s[i] and s[i + 1] < s[i]:
			flag = True
			break
	if flag:
		print('YES')
		print(i, i + 1, i + 2)
	else:
		print('NO')


from math import *
sInt = lambda : int(input())
mInt = lambda : map(int, input().split())
lInt = lambda : list(map(int, input().split()))
t = sInt()
for _ in range(t):
	n = sInt()
	a = lInt()
	i = 0
	j = n - 1
	while len(a[i:j]) >= 2:
		ans = a.index(max(a))
		if ans == i:
			i += 1
			a[ans] = -10000
		elif ans == j:
			j -= 1
			a[ans] = -10000
		else:
			break
	if len(a[i:j]) >= 2:
		print('YES')
		print(ans, ans + 1, ans + 2)
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	flag = 0
	for j in range(1, n - 1):
		i = j - 1
		k = j + 1
		if p[j] > p[k] and p[j] > p[i]:
			print('YES')
			print(i + 1, j + 1, k + 1)
			flag = 1
			break
	if flag == 0:
		print('NO')


T = int(input())
while T:
	T -= 1
	n = int(input())
	p = list(map(int, input().split()))
	flag = 1
	for _ in range(n - 2):
		if p[_] < p[_ + 1] and p[_ + 1] > p[_ + 2]:
			print('YES')
			print(_ + 1, _ + 2, _ + 3)
			flag = 0
			break
	if flag:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	c = 1
	p = list(map(int, input().split()))
	for j in range(n):
		if j < n - 2 and p[j] < p[j + 1] and (p[j + 1] > p[j + 2]):
			c = 0
			a = j
			break
	if c == 0:
		print('yes')
		print(a + 1, a + 2, a + 3)
	else:
		print('no')


def permutation(n, p):
	for x in range(n - 2):
		if p[x + 1] > p[x] and p[x + 1] > p[x + 2]:
			return ' '.join(list(map(str, [x + 1, x + 2, x + 3])))
	return 'NO'
t = int(input())
ans = []
for y in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	a = permutation(n, p)
	if a == 'NO':
		ans.append(a)
	else:
		ans.append('YES')
		ans.append(a)
for y in ans:
	print(y)


t = int(input())
while t:
	n = int(input())
	a = list(map(int, input().split()))
	(k, u, v, w) = (0, 0, 0, 0)
	for x in range(1, n):
		if a[x] > a[x - 1]:
			k = 1
			u = x - 1
			v = x
		if a[x] < a[x - 1] and k == 1:
			v = x - 1
			w = x
			k = 2
			break
	if k == 2:
		print('YES')
		print(u + 1, v + 1, w + 1)
	else:
		print('NO')
	t -= 1


for i in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	flg = 0
	for i in range(1, n - 1):
		flg1 = flg2 = 0
		for j in range(i):
			if a[j] < a[i]:
				flg1 = 1
				break
		for k in range(i, n):
			if a[k] < a[i]:
				flg2 = 1
				break
		if flg1 == 1 and flg2 == 1:
			print('YES')
			print(j + 1, i + 1, k + 1)
			flg = 1
			break
	if flg == 0:
		print('NO')


T = int(input())
for s in range(0, T):
	n = int(input())
	p = tuple((int(k) for k in input().split()))
	(i, j, k) = (0, 0, 0)
	b = False
	for j in range(1, n - 1):
		b1 = False
		for i in range(0, j):
			if p[i] < p[j]:
				b1 = True
				break
		b2 = False
		for k in range(j + 1, n):
			if p[k] < p[j]:
				b2 = True
				break
		b = b1 and b2
		if b:
			break
	if b:
		print('YES\n', i + 1, j + 1, k + 1)
	else:
		print('NO')


T = int(input())
a = []
ans = []
while T:
	T -= 1
	(i, j, k) = (0, 1, 2)
	n = int(input())
	a = input().split()
	while k < n:
		if int(a[i]) < int(a[j]) and int(a[j]) > int(a[k]):
			print('YES')
			print(i + 1, j + 1, k + 1, end=' ')
			print(end='\n')
			break
		else:
			i += 1
			j += 1
			k += 1
		if k == n:
			print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	perm = list(map(int, input().split()))
	lowone = perm[0]
	high = 0
	lowtwo = 0
	indone = 0
	indtwo = 0
	indthree = 0
	counter = 0
	for i in perm:
		if high == 0:
			if i < lowone:
				lowone = i
				indone = counter
			if i > lowone:
				high = i
				indtwo = counter
		elif lowtwo == 0:
			if i > high:
				high = i
				indtwo = counter
			if i < high:
				lowtwo = i
				indthree = counter
				break
		counter += 1
	if indtwo and indthree:
		print('YES')
		print(indone + 1, indtwo + 1, indthree + 1)
	else:
		print('NO')


from collections import defaultdict as dd
from collections import deque
import bisect
import heapq

def ri():
	return int(input())

def rl():
	return list(map(int, input().split()))
q = ri()
for _ in range(q):
	n = ri()
	a = rl()
	found = False
	for k in range(1, n - 1):
		if a[k - 1] < a[k] and a[k] > a[k + 1]:
			print('YES')
			print(*[k, k + 1, k + 2])
			found = True
			break
	if found == False:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	lista = [int(j) for j in input().split()]
	menor_e = 0
	maior = -1
	menor_d = -1
	for i in range(1, n):
		if maior == -1:
			if lista[i] > lista[menor_e]:
				maior = i
			else:
				menor_e = i
		elif lista[i] > lista[maior]:
			maior = i
		else:
			menor_d = i
			break
	if menor_d == -1:
		print('NO')
	else:
		print('YES')
		print(menor_e + 1, maior + 1, menor_d + 1)


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	l = []
	f = 0
	for i in range(n):
		f = 0
		for z in range(i + 1, n):
			if p[i] < p[z]:
				f = 1
				l.append((i, z))
				break
	x = 0
	for _ in range(len(l)):
		x = 0
		for j in range(l[_][1], n):
			if p[l[_][1]] > p[j]:
				x = 1
				break
		if x == 1:
			break
	if l == [] or x == 0:
		print('NO')
	else:
		print('YES')
		print(l[_][0] + 1, l[_][1] + 1, j + 1)


def solution(arr):
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			return i
	return -1
for _ in range(int(input())):
	n = int(input())
	arr = [int(x) for x in input().split()]
	ans = solution(arr)
	if ans == -1:
		print('NO')
	else:
		print('YES')
		print(ans, ans + 1, ans + 2)


import sys
import math
import collections
import heapq
import queue
import itertools
import functools
import operator
import time
readline = sys.stdin.readline
IPS = lambda : readline().rstrip()
IP = lambda : int(readline().rstrip())
MP = lambda : map(int, readline().split())
LS = lambda : list(map(int, readline().split()))

def solve():
	for _ in range(IP()):
		n = IP()
		arr = LS()
		fg = 0
		for i in range(n):
			(j, k) = (-1, -1)
			for tp in range(i + 1, n):
				if arr[tp] > arr[i]:
					j = tp
					break
			if j != -1:
				for tp in range(j + 1, n):
					if arr[tp] < arr[j]:
						k = tp
						break
			if j != -1 and k != -1:
				print('YES')
				fg = 1
				print(i + 1, j + 1, k + 1)
				break
		if not fg:
			print('NO')
solve()


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	ind = [0] * (n + 1)
	for (i, v) in enumerate(l):
		ind[v] = i
	found = False
	for i in range(n, 2, -1):
		if l[0] != i and l[i - 1] != i:
			found = True
			print('YES')
			print(ind[l[0]] + 1, ind[i] + 1, ind[l[i - 1]] + 1)
			break
		elif l[0] == i:
			l.pop(0)
		else:
			l.pop(i - 1)
	if not found:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	(i, j, k) = (0, None, None)
	for z in range(1, n):
		if arr[z] < arr[z - 1]:
			i = z
		else:
			j = z
			break
	if j is None:
		print('NO')
		continue
	for z in range(j + 1, n):
		if arr[z] > arr[z - 1]:
			j = z
		else:
			k = z
			break
	if None in (i, j, k):
		print('NO')
	else:
		print('YES')
		print(i + 1, j + 1, k + 1)


def tell(a, n):
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
number_o_v = int(input())
for i in range(number_o_v):
	n = int(input())
	a = list(map(int, input().split(' ')))
	tell(a, n)


t = int(input())
from collections import Counter
for _ in range(t):
	n = int(input())
	inp = list(map(int, input().split()))
	c = Counter([])
	for i in range(len(inp)):
		c[inp[i]] = i
	flag = 0
	for i in range(n, 0, -1):
		if c[i] != 0 and c[i] != len(inp) - 1:
			if max(inp[c[i] + 1], inp[c[i] - 1]) < inp[c[i]]:
				print('YES')
				print(c[i], end=' ')
				print(c[i] + 1, end=' ')
				print(c[i] + 2)
				flag = 1
				break
	if flag == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	lis = list(map(int, input().split()))
	num = [0 for i in range(n + 1)]
	c = 1
	for i in lis:
		num[i] = c
		c += 1
	l = 1
	r = n
	i1 = -1
	for i in range(n, 0, -1):
		if num[i] == l or num[i] == r:
			if num[i] == l:
				l += 1
			else:
				r -= 1
		else:
			i1 = num[i]
			break
	if i1 == -1:
		print('NO')
	else:
		print('YES')
		print(i1 - 1, i1, i1 + 1)


t = int(input())
(FIND_PEAK, FIND_RIGHT) = (0, 1)
for foo in range(t):
	n = int(input())
	p = list(map(lambda x: int(x), input().strip().split(' ')))
	s = p[0]
	si = 0
	STATE = FIND_PEAK
	b = -1
	r = -1
	for i in range(1, n):
		if STATE == FIND_PEAK:
			if p[i] > s:
				b = p[i]
				bi = i
				STATE = FIND_RIGHT
			else:
				s = p[i]
				si = i
		elif p[i] < b:
			r = p[i]
			ri = i
			break
		else:
			b = p[i]
			bi = i
	if b != -1 and r != -1:
		print('YES')
		print('%d %d %d' % (si + 1, bi + 1, ri + 1))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	minv = l[0]
	minvl = []
	for x in l:
		minvl.append(minv)
		if x < minv:
			minv = x
	minv = l[n - 1]
	minvl2 = []
	for i in range(n):
		minvl2.append(minv)
		j = n - i - 1
		if l[j] < minv:
			minv = l[j]
	minvl2 = minvl2[::-1]
	i = 0
	poss = False
	for ind in range(1, n - 1):
		if minvl[ind] < l[ind] and minvl2[ind] < l[ind]:
			i = ind
			poss = True
			break
	if not poss:
		print('NO')
	else:
		print('YES')
		j = 0
		k = n - 1
		for ind in range(n):
			if ind < i and l[ind] < l[i]:
				j = ind
			elif ind > i and l[ind] < l[i]:
				k = ind
				break
		print(j + 1, i + 1, k + 1)


import math
c = int(input())
for _ in range(c):
	n = int(input())
	arr = [int(x) for x in input().split()]
	s = []
	found = False
	for i in range(n):
		if len(s) >= 2:
			if arr[i] < arr[s[-1]]:
				three = i
				two = s.pop()
				one = s.pop()
				print('YES')
				print('{} {} {}'.format(one + 1, two + 1, three + 1))
				found = True
				break
			else:
				s.append(i)
		else:
			while s and arr[i] < arr[s[-1]]:
				s.pop()
			s.append(i)
	if not found:
		print('NO')


def ans_slow(p):
	for i in range(len(p)):
		for j in range(i + 1, len(p)):
			for k in range(j + 1, len(p)):
				if p[j] > p[i] and p[j] > p[k]:
					return (i + 1, j + 1, k + 1)
	return None

def ans(p):
	for i in range(len(p) - 2):
		j = i + 1
		k = j + 1
		if p[j] > p[i] and p[j] > p[k]:
			return (i + 1, j + 1, k + 1)
	return None
T = int(input())
for t in range(T):
	input()
	p = input().split(' ')
	p = list(map(int, p))
	r = ans(p)
	if r is None:
		print('NO')
	else:
		print('YES')
		print(*r)


n = int(input())
while n > 0:
	k = int(input())
	l = [int(x) for x in input().split()]
	c = []
	flag = 0
	for i in range(0, k - 2):
		if l[i] < l[i + 1] and l[i + 1] > l[i + 2]:
			ans = i
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(i + 1, i + 2, i + 3)
	else:
		print('NO')
	n -= 1


import sys

def input():
	return sys.stdin.readline().rstrip()

def input_split():
	return [int(i) for i in input().split()]
testCases = int(input())
answers = []
for _ in range(testCases):
	n = int(input())
	arr = input_split()
	prob1 = list(range(1, n + 1))
	prob2 = prob1.copy()
	prob2.reverse()
	increased_index = None
	increased = False
	done = False
	for i in range(1, n):
		if increased and arr[i - 1] > arr[i]:
			ans = 'YES\n{} {} {}'.format(increased_index + 1, i, i + 1)
			done = True
			break
		elif not increased and arr[i - 1] < arr[i]:
			increased = True
			increased_index = i - 1
	if not done:
		ans = 'NO'
	answers.append(ans)
print(*answers, sep='\n')


import sys
input = sys.stdin.readline
I = lambda : list(map(int, input().split()))
(t,) = I()
for i in range(t):
	(n,) = I()
	l = I()
	a = b = c = 0
	ma = n + 1
	mi = 0
	for i in range(n - 1, -1, -1):
		if ma == 0 and l[i] == n:
			n -= 1
		elif c == 0 or (b == 0 and l[i] < ma):
			c = i + 1
			ma = l[i]
		elif b == 0 or (a == 0 and l[i] > mi):
			b = i + 1
			mi = l[i]
		elif l[i] < mi and mi > ma:
			a = i + 1
			break
	if a:
		print('YES')
		print(a, b, c)
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = [int(i) for i in input().split()]
	f = 0
	for i in range(len(a) - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			f = 1
			print('YES', end='\n')
			print(i + 1, i + 2, i + 3, end='\n')
			break
	if f == 0:
		print('NO', end='\n')


import sys
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	stat = 0
	for i in range(n - 1):
		if stat == 0 and p[i] < p[i + 1]:
			stat = 1
			x = i + 1
			y = i + 2
		elif stat == 1 and p[i] < p[i + 1]:
			y = i + 2
		elif stat == 1 and p[i] > p[i + 1]:
			z = i + 2
			print('YES')
			print(x, y, z)
			break
	else:
		print('NO')


def check(tab):
	i = 0
	j = 0
	k = 0
	counter = 0
	while counter < len(tab) - 1 and tab[counter] >= tab[counter + 1]:
		counter += 1
		i += 1
	if counter >= len(tab) - 1:
		return 'NO'
	counter = i + 1
	j = i + 1
	while counter < len(tab) - 1 and tab[counter] <= tab[counter + 1]:
		counter += 1
		j += 1
	if counter >= len(tab) - 1:
		return 'NO'
	counter = j + 1
	k = j + 1
	return 'YES\n' + str(i + 1) + ' ' + str(j + 1) + ' ' + str(k + 1)
x = input()
for i in range(0, int(x)):
	n = int(input())
	tab = [int(num) for num in input().split(' ')]
	print(check(tab))


for _ in range(int(input())):
	n = int(input())
	flag = False
	listt = [int(e) for e in input().split()]
	for j in range(1, len(listt) - 1):
		if listt[j - 1] < listt[j] and listt[j] > listt[j + 1]:
			i1 = j
			i2 = j + 1
			i3 = j + 2
			flag = True
			break
	if flag:
		print('YES')
		print(i1, i2, i3)
	else:
		print('NO')


t = input()
t = int(t)
while t > 0:
	t -= 1
	n = int(input())
	v = list(map(int, input().strip().split()))[0:n]
	f = -1
	for i in range(1, n - 1):
		if v[i] > v[i - 1] and v[i] > v[i + 1]:
			f = i + 1
			break
	if f == -1:
		print('NO')
	else:
		print('YES')
		print(f - 1, f, f + 1)


import os
import sys
from io import BytesIO, IOBase
from collections import Counter, defaultdict
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')
primes = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269, 271, 277, 281, 283, 293, 307, 311, 313, 317, 331, 337, 347, 349, 353, 359, 367, 373, 379, 383, 389, 397, 401, 409, 419, 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 503, 509, 521, 523, 541, 547, 557, 563, 569, 571, 577, 587, 593, 599, 601, 607, 613, 617, 619, 631, 641, 643, 647, 653, 659, 661, 673, 677, 683, 691, 701, 709, 719, 727, 733, 739, 743, 751, 757, 761, 769, 773, 787, 797, 809, 811, 821, 823, 827, 829, 839, 853, 857, 859, 863, 877, 881, 883, 887, 907, 911, 919, 929, 937, 941, 947, 953, 967, 971, 977, 983, 991, 997, 1009, 1013, 1019, 1021, 1031, 1033, 1039, 1049, 1051, 1061, 1063, 1069, 1087, 1091, 1093, 1097, 1103, 1109, 1117, 1123, 1129, 1151, 1153, 1163, 1171, 1181, 1187, 1193, 1201, 1213, 1217, 1223, 1229, 1231, 1237, 1249, 1259, 1277, 1279, 1283, 1289, 1291, 1297, 1301, 1303, 1307, 1319, 1321, 1327, 1361, 1367, 1373, 1381, 1399, 1409, 1423, 1427, 1429, 1433, 1439, 1447, 1451, 1453, 1459, 1471, 1481, 1483, 1487, 1489, 1493, 1499, 1511, 1523, 1531, 1543, 1549, 1553, 1559, 1567, 1571, 1579, 1583, 1597, 1601, 1607, 1609, 1613, 1619, 1621, 1627, 1637, 1657, 1663, 1667, 1669, 1693, 1697, 1699, 1709, 1721, 1723, 1733, 1741, 1747, 1753, 1759, 1777, 1783, 1787, 1789, 1801, 1811, 1823, 1831, 1847, 1861, 1867, 1871, 1873, 1877, 1879, 1889, 1901, 1907, 1913, 1931, 1933, 1949, 1951, 1973, 1979, 1987, 1993, 1997, 1999, 2003, 2011, 2017, 2027, 2029, 2039, 2053, 2063, 2069, 2081, 2083, 2087, 2089, 2099, 2111, 2113, 2129, 2131, 2137, 2141, 2143, 2153, 2161, 2179, 2203, 2207, 2213, 2221, 2237, 2239, 2243, 2251, 2267, 2269, 2273, 2281, 2287, 2293, 2297, 2309, 2311, 2333, 2339, 2341, 2347, 2351, 2357, 2371, 2377, 2381, 2383, 2389, 2393, 2399, 2411, 2417, 2423, 2437, 2441, 2447, 2459, 2467, 2473, 2477, 2503, 2521, 2531, 2539, 2543, 2549, 2551, 2557, 2579, 2591, 2593, 2609, 2617, 2621, 2633, 2647, 2657, 2659, 2663, 2671, 2677, 2683, 2687, 2689, 2693, 2699, 2707, 2711, 2713, 2719, 2729, 2731, 2741, 2749, 2753, 2767, 2777, 2789, 2791, 2797, 2801, 2803, 2819, 2833, 2837, 2843, 2851, 2857, 2861, 2879, 2887, 2897, 2903, 2909, 2917, 2927, 2939, 2953, 2957, 2963, 2969, 2971, 2999, 3001, 3011, 3019, 3023, 3037, 3041, 3049, 3061, 3067, 3079, 3083, 3089, 3109, 3119, 3121, 3137, 3163, 3167, 3169, 3181, 3187, 3191, 3203, 3209, 3217, 3221, 3229, 3251, 3253, 3257, 3259, 3271, 3299, 3301, 3307, 3313, 3319, 3323, 3329, 3331, 3343, 3347, 3359, 3361, 3371, 3373, 3389, 3391, 3407, 3413, 3433, 3449, 3457, 3461, 3463, 3467, 3469, 3491, 3499, 3511, 3517, 3527, 3529, 3533, 3539, 3541, 3547, 3557, 3559, 3571, 3581, 3583, 3593, 3607, 3613, 3617, 3623, 3631, 3637, 3643, 3659, 3671, 3673, 3677, 3691, 3697, 3701, 3709, 3719, 3727, 3733, 3739, 3761, 3767, 3769, 3779, 3793, 3797, 3803, 3821, 3823, 3833, 3847, 3851, 3853, 3863, 3877, 3881, 3889, 3907, 3911, 3917, 3919, 3923, 3929, 3931, 3943, 3947, 3967, 3989, 4001, 4003, 4007, 4013, 4019, 4021, 4027, 4049, 4051, 4057, 4073, 4079, 4091, 4093, 4099, 4111, 4127, 4129, 4133, 4139, 4153, 4157, 4159, 4177, 4201, 4211, 4217, 4219, 4229, 4231, 4241, 4243, 4253, 4259, 4261, 4271, 4273, 4283, 4289, 4297, 4327, 4337, 4339, 4349, 4357, 4363, 4373, 4391, 4397, 4409, 4421, 4423, 4441, 4447, 4451, 4457, 4463, 4481, 4483, 4493, 4507, 4513, 4517, 4519, 4523, 4547, 4549, 4561, 4567, 4583, 4591, 4597, 4603, 4621, 4637, 4639, 4643, 4649, 4651, 4657, 4663, 4673, 4679, 4691, 4703, 4721, 4723, 4729, 4733, 4751, 4759, 4783, 4787, 4789, 4793, 4799, 4801, 4813, 4817, 4831, 4861, 4871, 4877, 4889, 4903, 4909, 4919, 4931, 4933, 4937, 4943, 4951, 4957, 4967, 4969, 4973, 4987, 4993, 4999, 5003, 5009, 5011, 5021, 5023, 5039, 5051, 5059, 5077, 5081, 5087, 5099, 5101, 5107, 5113, 5119, 5147, 5153, 5167, 5171, 5179, 5189, 5197, 5209, 5227, 5231, 5233, 5237, 5261, 5273, 5279, 5281, 5297, 5303, 5309, 5323, 5333, 5347, 5351, 5381, 5387, 5393, 5399, 5407, 5413, 5417, 5419, 5431, 5437, 5441, 5443, 5449, 5471, 5477, 5479, 5483, 5501, 5503, 5507, 5519, 5521, 5527, 5531, 5557, 5563, 5569, 5573, 5581, 5591, 5623, 5639, 5641, 5647, 5651, 5653, 5657, 5659, 5669, 5683, 5689, 5693, 5701, 5711, 5717, 5737, 5741, 5743, 5749, 5779, 5783, 5791, 5801, 5807, 5813, 5821, 5827, 5839, 5843, 5849, 5851, 5857, 5861, 5867, 5869, 5879, 5881, 5897, 5903, 5923, 5927, 5939, 5953, 5981, 5987, 6007, 6011, 6029, 6037, 6043, 6047, 6053, 6067, 6073, 6079, 6089, 6091, 6101, 6113, 6121, 6131, 6133, 6143, 6151, 6163, 6173, 6197, 6199, 6203, 6211, 6217, 6221, 6229, 6247, 6257, 6263, 6269, 6271, 6277, 6287, 6299, 6301, 6311, 6317, 6323, 6329, 6337, 6343, 6353, 6359, 6361, 6367, 6373, 6379, 6389, 6397, 6421, 6427, 6449, 6451, 6469, 6473, 6481, 6491, 6521, 6529, 6547, 6551, 6553, 6563, 6569, 6571, 6577, 6581, 6599, 6607, 6619, 6637, 6653, 6659, 6661, 6673, 6679, 6689, 6691, 6701, 6703, 6709, 6719, 6733, 6737, 6761, 6763, 6779, 6781, 6791, 6793, 6803, 6823, 6827, 6829, 6833, 6841, 6857, 6863, 6869, 6871, 6883, 6899, 6907, 6911, 6917, 6947, 6949, 6959, 6961, 6967, 6971, 6977, 6983, 6991, 6997, 7001, 7013, 7019, 7027, 7039, 7043, 7057, 7069, 7079, 7103, 7109, 7121, 7127, 7129, 7151, 7159, 7177, 7187, 7193, 7207, 7211, 7213, 7219, 7229, 7237, 7243, 7247, 7253, 7283, 7297, 7307, 7309, 7321, 7331, 7333, 7349, 7351, 7369, 7393, 7411, 7417, 7433, 7451, 7457, 7459, 7477, 7481, 7487, 7489, 7499, 7507, 7517, 7523, 7529, 7537, 7541, 7547, 7549, 7559, 7561, 7573, 7577, 7583, 7589, 7591, 7603, 7607, 7621, 7639, 7643, 7649, 7669, 7673, 7681, 7687, 7691, 7699, 7703, 7717, 7723, 7727, 7741, 7753, 7757, 7759, 7789, 7793, 7817, 7823, 7829, 7841, 7853, 7867, 7873, 7877, 7879, 7883, 7901, 7907, 7919]
from math import ceil

def lmii():
	return list(map(int, input().split()))
t = int(input())
for i in range(t):
	n = int(input())
	nums = lmii()
	ans = None
	for i in range(n - 2):
		if nums[i] < nums[i + 1] > nums[i + 2]:
			ans = i
			break
	if ans is None:
		print('NO')
	else:
		print('YES')
		print(ans + 1, ans + 2, ans + 3)


def main():
	from sys import stdin, stdout
	for _ in range(int(stdin.readline())):
		n = int(stdin.readline())
		arr = list(map(int, stdin.readline().split()))
		mod_arr = []
		for i in range(1, n):
			mod_arr.append(arr[i] - arr[i - 1])
		flag = False
		indice = 0
		for i in range(n - 2):
			if mod_arr[i] > 0 and mod_arr[i + 1] < 0:
				flag = True
				indice = i
				break
		if flag:
			stdout.write('YES\n')
			ans = str(indice + 1) + ' ' + str(indice + 2) + ' ' + str(indice + 3) + '\n'
			stdout.write(ans)
		else:
			stdout.write('NO\n')
main()


def solve(n, p):
	var = True
	for i in range(n - 2):
		if p[i] < p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			var = False
			break
	if var:
		print('NO')
t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	solve(n, p)


import os
from io import BytesIO, IOBase
import sys

def main():
	for _ in range(int(input())):
		n = int(input())
		a = list(map(int, input().split()))
		(l, r) = (1, n)
		ans = (0, 0, 0)
		while r - l + 1 >= 3:
			if a[l - 1] == r - l + 1:
				l += 1
			elif a[r - 1] == r - l + 1:
				r -= 1
			else:
				p = 0
				for i in range(l, r + 1):
					if a[i - 1] == r - l + 1:
						p = i
						break
				ans = (l, p, r)
				break
		if ans == (0, 0, 0):
			print('NO')
		else:
			print('YES')
			print(*ans)
	return
BUFSIZE = 1048576

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))

def input():
	return sys.stdin.readline().rstrip('\r\n')
main()


t = int(input())
for s in range(t):
	n = int(input())
	array = list(map(int, input().split()))
	array = [0] + array
	store = 0
	flag = 0
	for i in range(2, n):
		if array[i] - array[i - 1] > 0:
			if array[i] - array[i + 1] > 0:
				flag = 1
				store = i
				break
	if flag == 1:
		print('YES')
		for j in range(i - 1, i + 2):
			print(j, end=' ')
	else:
		print('NO')
	print()


t = int(input())
ans = []
for i in range(t):
	n = int(input())
	nums = list(map(int, input().split()))
	check = False
	for j in range(1, n - 1):
		if nums[j - 1] < nums[j] and nums[j + 1] < nums[j]:
			check = True
			ans.append(('YES', j + 1))
		if check:
			break
	if not check:
		ans.append('NO')
for i in ans:
	if i == 'NO':
		print('NO')
	else:
		print('YES')
		print(i[1] - 1, i[1], i[1] + 1)


for _ in range(int(input())):
	n = int(input())
	a = [int(i) for i in input().split()]
	l = 0
	r = n
	ans = -1
	x = n
	while 1:
		if x == 1:
			break
		ind = a[l:r].index(x) + l
		if ind == l:
			l += 1
		elif ind == r - 1:
			r -= 1
		else:
			ans = ind
			break
		x -= 1
	if ans != -1:
		print('YES')
		print(l + 1, ind + 1, r)
	else:
		print('NO')


import sys
input = sys.stdin.readline
for nt in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	curr = 0
	ans = 'NO'
	for i in range(1, n):
		if a[i] < a[i - 1] and (not curr):
			continue
		elif a[i] < a[i - 1] and curr:
			ans = 'YES'
			break
		elif a[i] > a[i - 1] and (not curr):
			curr = 1
	print(ans)
	if ans == 'YES':
		for i in range(1, n - 1):
			if a[i] > a[i - 1] and a[i] > a[i + 1]:
				print(i, i + 1, i + 2)
				break


import string
get_int = lambda : int(input())
get_mul_int = lambda : map(int, input().rstrip().split())
get_list = lambda : list(map(int, input().rstrip().split()))
TEST_CASES = True

def main():
	n = get_int()
	a = get_list()
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
if not TEST_CASES:
	main()
else:
	[main() for _ in range(int(input()))]


num_cases = int(input())
o = ''
for nc in range(num_cases):
	found = False
	n = int(input())
	nums = list(map(int, input().split()))
	copy_nums = {nums[i]: i + 1 for i in range(len(nums))}
	sort_num = sorted(nums, reverse=True)
	for num in sort_num:
		max_index = nums.index(num)
		lower = nums[:max_index]
		higher = nums[max_index + 1:]
		if len(lower) > 0 and len(higher) > 0:
			o += 'YES\n'
			o += f'{copy_nums[lower[0]]} {copy_nums[max(nums)]} {copy_nums[higher[-1]]}\n'
			found = True
			break
		nums.pop(max_index)
	if not found:
		o += 'NO\n'
print(o, end='')


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	diff = []
	for i in range(1, n):
		d = arr[i - 1] - arr[i]
		diff.append(d)
	k = 0
	i = 0
	for l in range(0, n - 1):
		if diff[l] < 0:
			j = l + 2
			if l + 1 < n - 1:
				if diff[l + 1] > 0:
					k = l + 3
					i = l + 1
					break
				else:
					continue
		else:
			j = 0
	if k > 0:
		print('YES')
		print(i, j, k)
	else:
		print('NO')


for lo in range(int(input())):
	n = int(input())
	ls = [int(x) for x in input().split()]
	a = [n for i in range(n)]
	a1 = [i for i in range(n)]
	b = [0 for j in range(n)]
	b1 = [i for i in range(n)]
	a[0] = ls[0]
	b[n - 1] = ls[n - 1]
	for i in range(1, n):
		if ls[i] > a[i - 1]:
			a[i] = a[i - 1]
			a1[i] = a1[i - 1]
		else:
			a[i] = ls[i]
	for i in range(n - 2, 0, -1):
		if ls[i] > b[i + 1]:
			b[i] = b[i + 1]
			b1[i] = b1[i + 1]
		else:
			b[i] = ls[i]
	ans = 'NO'
	x = y = z = 0
	for i in range(1, n - 1):
		if ls[i] > a[i - 1] and ls[i] > b[i + 1]:
			x = a1[i - 1] + 1
			y = i + 1
			z = b1[i + 1] + 1
			ans = 'YES'
			break
	print(ans)
	if ans == 'YES':
		print(x, y, z)


t = int(input())
for _ in range(t):
	n = int(input())
	nums = list(map(int, input().split()))
	lmin = [0] * n
	rmin = [n - 1] * n
	for i in range(n):
		lmin[i] = i if nums[lmin[i]] > nums[i] else lmin[i]
	for i in range(n - 1, -1, -1):
		rmin[i] = i if nums[rmin[i]] > nums[i] else rmin[i]
	for i in range(1, n - 1):
		if nums[i] > nums[lmin[i - 1]] and nums[i] > nums[rmin[i + 1]]:
			print('YES', lmin[i - 1] + 1, i + 1, rmin[i + 1] + 1)
			break
	else:
		print('NO')


t = int(input())
for ii in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	inc = True
	dec = True
	temp = []
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			temp.extend([i, i + 1, i + 2])
			break
	if len(temp) == 0:
		print('NO')
	else:
		print('YES')
		print(*temp)


import math
import bisect
import copy
import time
from collections import Counter
for _ in range(int(input())):
	n = int(input())
	l = [int(x) for x in input().split()]
	(i, j, k) = (0, 0, 0)
	(ff, fff) = (-1, -1)
	for ii in range(1, len(l)):
		ff = -1
		fff = -1
		for jj in range(0, ii):
			if l[jj] < l[ii]:
				ff = jj
				break
		for kk in range(ii + 1, n):
			if l[kk] < l[ii]:
				fff = kk
				break
		if ff != -1 and fff != -1:
			print('YES')
			print(ff + 1, ii + 1, fff + 1)
			break
	if ff == -1 or fff == -1:
		print('NO')


T = int(input(''))
for i in range(T):
	n = int(input())
	linea_p = input().split()
	p = []
	for elem in linea_p:
		p.append(int(elem))
	indmin = 0
	indmax = n - 1
	curmax = n
	while curmax > 2:
		if p[indmax] == curmax:
			curmax -= 1
			indmax -= 1
			continue
		if p[indmin] == curmax:
			curmax -= 1
			indmin += 1
			continue
		for j in range(indmin, indmax + 1):
			if p[j] == curmax:
				print('YES')
				print(indmin + 1, j + 1, indmax + 1)
		break
	else:
		print('NO')


import sys
import math
import bisect
from sys import stdin
from itertools import groupby
from heapq import heapify, heappop, heappush
from collections import deque, Counter, OrderedDict

def neo():
	return map(int, input().split())

def Neo():
	return list(map(int, input().split()))
for _ in range(int(input())):
	N = int(input())
	A = Neo()
	flag = 0
	for i in range(N):
		(a, b, c) = (i, 0, 0)
		maxi = A[i]
		for j in range(i + 1, N):
			if A[j] > maxi:
				maxi = A[j]
				b = j
			elif b > 0:
				c = j
				flag = 1
				break
		if flag == 1:
			break
	if flag == 1:
		print('YES')
		print(a + 1, b + 1, c + 1)
	else:
		print('NO')


t = int(input())
for tt in range(t):
	n = int(input())
	x = list(map(int, input().split()))
	flag = 0
	if n > 2:
		for i in range(1, n - 1):
			if x[i - 1] < x[i] and x[i] > x[i + 1]:
				flag = 1
				j = i
	if flag == 0:
		print('NO')
	else:
		print('YES')
		print(j, j + 1, j + 2)


t = int(input())
for i in range(t):
	n = int(input())
	b = list(map(int, input().split()))
	d = dict()
	for j in range(n):
		d[b[j]] = j
	j = n
	p = 0
	q = n - 1
	f = 0
	while j >= 1:
		if d[j] == p:
			p += 1
		elif d[j] == q:
			q += -1
		else:
			f = 1
			break
		j += -1
	if f == 1:
		print('YES')
		print(p + 1, d[j] + 1, q + 1)
	else:
		print('NO')


test_cases = int(input())
for t in range(test_cases):
	n = int(input())
	sequence = [int(v) for v in input().split(' ')]
	(i, j, k) = (0, None, None)
	for (index, num) in enumerate(sequence):
		if j is None:
			if num > sequence[i]:
				j = index
			else:
				i = index
		elif k is None:
			if num < sequence[j]:
				k = index
				break
			else:
				j = index
	if j is None or k is None:
		print('No')
	else:
		print('YES')
		print(i + 1, j + 1, k + 1)


from sys import stdin, stdout
from math import gcd, sqrt
from collections import deque
input = stdin.readline
R = lambda : map(int, input().split())
I = lambda : int(input())
S = lambda : input().rstrip('\n')
L = lambda : list(R())
P = lambda x: stdout.write(x)
lcm = lambda x, y: x * y // gcd(x, y)
hg = lambda x, y: (y + x - 1) // x * x
pw = lambda x: 1 if x == 1 else 1 + pw(x // 2)
chk = lambda x: chk(x // 2) if not x % 2 else True if x == 1 else False
sm = lambda x: (x ** 2 + x) // 2
N = 10 ** 9 + 7
for _ in range(I()):
	n = I()
	a = L()
	flg = 1
	for i in range(n - 2):
		if a[i] < a[i + 1] > a[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			flg = 0
			break
	if flg:
		print('NO')


for cases in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	flag = 0
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			a = i - 1
			b = i
			c = i + 1
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(a + 1, b + 1, c + 1)
	else:
		print('NO')


testCases = int(input())
for _ in range(testCases):
	size = int(input())
	nums = list(map(int, input().split()))
	heap = []
	isFound = False
	for pos in range(1, len(nums) - 1):
		if pos == 0:
			continue
		if nums[pos] > nums[pos - 1] and nums[pos] > nums[pos + 1]:
			isFound = True
			print('YES')
			print(pos, pos + 1, pos + 2)
			break
	if isFound == False:
		print('NO')


import copy

def main():
	for _ in range(int(input())):
		n = int(input())
		a = list(map(int, input().split()))
		(premin, postmin) = ([a[0]], [a[-1]])
		(premini, postmini) = ([0], [n - 1])
		mini = a[0]
		minii = 0
		for i in range(1, n):
			premin.append(min(mini, a[i]))
			if a[minii] > a[i]:
				minii = i
			premini.append(minii)
			mini = min(mini, a[i])
		mini = a[-1]
		minii = n - 1
		for i in range(n - 2, -1, -1):
			postmin.append(min(mini, a[i]))
			if a[minii] > a[i]:
				minii = i
			postmini.append(minii)
			mini = min(mini, a[i])
		postmin = postmin[::-1]
		postmini = postmini[::-1]
		flag = -1
		for i in range(1, n - 1):
			if premin[i - 1] < a[i] > postmin[i + 1]:
				flag = i
				break
		if flag == -1:
			print('NO')
		else:
			print('YES')
			print(premini[i - 1] + 1, i + 1, postmini[i + 1] + 1)
main()


t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(x) for x in input().split()]
	flag = False
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = True
			break
	if not flag:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	(left, right) = ([], [])
	mini = float('inf')
	for i in range(1, n - 1):
		if mini > l[i - 1]:
			mini = l[i - 1]
			left.append([mini, i - 1])
		else:
			left.append(left[-1])
	mini = float('inf')
	for i in range(n - 2, 0, -1):
		if mini > l[i + 1]:
			mini = l[i + 1]
			right.append([mini, i + 1])
		else:
			right.append(right[-1])
	right = right[::-1]
	flag = 0
	for i in range(1, n - 1):
		if l[i] > left[i - 1][0] and l[i] > right[i - 1][0]:
			flag = 1
			print('YES')
			print(left[i - 1][1] + 1, i + 1, right[i - 1][1] + 1)
			break
	if flag == 0:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	p = list(map(int, input().split()))

	def func(n, p):
		for i in range(1, n - 1):
			if p[i] > p[i - 1] and p[i] > p[i + 1]:
				print('YES')
				return str(i) + ' ' + str(i + 1) + ' ' + str(i + 2)
		return 'NO'
	print(func(n, p))


t = int(input())
for _ in range(t):
	n = input()
	p = list(map(lambda x: int(x), input().split()))
	first_number_index = 0
	i = 1
	while i <= len(p) - 1 and p[i] <= p[first_number_index]:
		first_number_index = i
		i += 1
	second_number_index = first_number_index + 1
	if second_number_index >= len(p) - 1:
		print('NO')
		continue
	i = second_number_index + 1
	while i <= len(p) - 1 and p[i] >= p[second_number_index]:
		second_number_index = i
		i += 1
	third_number_index = second_number_index + 1
	if third_number_index >= len(p):
		print('NO')
		continue
	print('YES')
	print(first_number_index + 1, second_number_index + 1, third_number_index + 1)


for _ in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	pos = [0] * (n + 1)
	for i in range(n):
		pos[arr[i]] = i
	l_min = [0] * (n - 2)
	r_min = [0] * (n - 2)
	curr_min = arr[0]
	for i in range(n - 2):
		curr_min = min(curr_min, arr[i])
		l_min[i] = curr_min
	curr_min = arr[-1]
	for i in range(n - 1, 1, -1):
		curr_min = min(curr_min, arr[i])
		r_min[i - 2] = curr_min
	ans = 'NO'
	for i in range(1, n - 1):
		if arr[i] > l_min[i - 1] and arr[i] > r_min[i - 1]:
			ans = 'YES'
			out = (pos[l_min[i - 1]] + 1, i + 1, pos[r_min[i - 1]] + 1)
	print(ans)
	if ans == 'YES':
		print(*out)


T = int(input())
for _ in range(T):
	n = int(input())
	arr = list(map(int, input().strip().split()))
	low = [-1 for _ in range(n)]
	high = [-1 for _ in range(n)]
	lowest = arr[0]
	lowest_idx = 0
	for i in range(1, n):
		if arr[i] < lowest:
			lowest = arr[i]
			lowest_idx = i
		elif lowest < arr[i]:
			low[i] = lowest_idx
	lowest = arr[n - 1]
	lowest_idx = n - 1
	for i in range(n - 2, -1, -1):
		if arr[i] < lowest:
			lowest = arr[i]
			lowest_idx = i
		elif lowest < arr[i]:
			high[i] = lowest_idx
	found = 0
	for i in range(n):
		if low[i] != -1 and high[i] != -1:
			print('YES\n%d %d %d' % (low[i] + 1, i + 1, high[i] + 1))
			found = 1
			break
	if found == 0:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	num_arr = input().split()
	for j in range(n):
		num_arr[j] = int(num_arr[j])
	f_num = str(num_arr[0])
	s_num = ''
	t_num = ''
	f_index = 0
	s_index = 0
	t_index = 0
	for j in range(n):
		if num_arr[j] < int(f_num) and s_num == '':
			f_num = str(num_arr[j])
			f_index = j
		if num_arr[j] > int(f_num):
			if s_num == '':
				s_num = str(num_arr[j])
				s_index = j
			elif num_arr[j] > int(s_num):
				s_num = str(num_arr[j])
				s_index = j
		if s_num != '':
			if num_arr[j] < int(s_num):
				t_num = str(num_arr[j])
				t_index = j
		if f_num != '' and s_num != '' and (t_num != ''):
			break
	if f_num != '' and s_num != '' and (t_num != ''):
		print('YES')
		print(str(f_index + 1) + ' ' + str(s_index + 1) + ' ' + str(t_index + 1))
	else:
		print('NO')


(z, zz) = (input, lambda : list(map(int, z().split())))
for _ in range(int(z())):
	t = int(z())
	l = zz()
	for i in range(1, t - 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


t = int(input())
for you in range(t):
	n = int(input())
	l = input().split()
	li = [int(i) for i in l]
	done = [1 for i in range(n)]
	hashi = dict()
	poss = 0
	for i in range(n):
		hashi[li[i]] = i
	for i in range(n, 0, -1):
		k = hashi[i]
		done[k] = 0
		if k == 0 or k == n - 1:
			continue
		if done[k - 1] == 0 or done[k + 1] == 0:
			continue
		poss = 1
		ans = k
	if poss:
		print('YES')
		print(ans, ans + 1, ans + 2)
	else:
		print('NO')


from __future__ import division, print_function
from sys import stdin, stdout
import bisect
import math
import heapq
i_m = 9223372036854775807

def inin():
	return int(input())

def stin():
	return input()

def spin():
	return map(int, stin().split())

def lin():
	return list(map(int, stin().split()))

def matrix(n):
	return [list(map(int, input().split())) for i in range(n)]

def calculate_sum(a, N):
	m = N / a
	sum = m * (m + 1) / 2
	ans = a * sum
	return ans

def series(N):
	return N * (N + 1) // 2

def count2Dmatrix(i, list):
	return sum((c.count(i) for c in list))

def modinv(n, p):
	return pow(n, p - 2, p)

def GCD(x, y):
	x = abs(x)
	y = abs(y)
	if min(x, y) == 0:
		return max(x, y)
	while y:
		(x, y) = (y, x % y)
	return x

def LCM(x, y):
	return x * y // GCD(x, y)

def Divisors(n):
	l = []
	for i in range(1, int(math.sqrt(n) + 1)):
		if n % i == 0:
			if n // i == i:
				l.append(i)
			else:
				l.append(i)
				l.append(n // i)
	return l

def isprime(n):
	for i in range(2, int(math.sqrt(n)) + 1):
		if n % i == 0:
			return False
	return True
prime = []

def SieveOfEratosthenes(n):
	global prime
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	f = []
	for p in range(2, n):
		if prime[p]:
			f.append(p)
	return f
q = []

def dfs(n, d, v, c):
	global q
	v[n] = 1
	x = d[n]
	q.append(n)
	j = c
	for i in x:
		if i not in v:
			f = dfs(i, d, v, c + 1)
			j = max(j, f)
	return j
for _ in range(inin()):
	n = inin()
	l = lin()
	flag = 0
	(a, b, c) = (0, 0, 0)
	for i in range(1, n - 1, 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			flag = 1
			a = i
			b = i + 1
			c = i + 2
			print('YES')
			print(a, b, c)
			break
	if flag == 0:
		print('NO')


testCases = int(input())
while testCases > 0:
	size = int(input())
	elements = list(map(int, input().split()))
	flag = False
	for m in range(1, size - 1):
		if elements[m - 1] < elements[m] and elements[m] > elements[m + 1]:
			print('YES')
			print(m, m + 1, m + 2)
			flag = True
			break
	if flag == False:
		print('NO')
	testCases -= 1


import sys, os
from io import BytesIO, IOBase
import collections, itertools, bisect, heapq, math, string
from decimal import *
BUFSIZE = 8192
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')

def main():
	t = int(input())
	for i in range(t):
		n = int(input())
		p = list(map(int, input().split()))
		f = False
		index = 0
		for i in range(1, n - 1):
			if p[i] > p[i - 1] and p[i] > p[i + 1]:
				f = True
				index = i
				break
		if f:
			print('YES')
			print(index, index + 1, index + 2)
		else:
			print('NO')
main()


a = int(input())
for i in range(a):
	s = int(input())
	z = list(map(int, input().split()))
	mini = 0
	maxa = -1
	flag = 0
	for i in range(1, len(z)):
		if z[i] > z[mini] and maxa == -1:
			maxa = i
		elif z[i] < z[mini] and maxa == -1:
			mini = i
		if maxa != -1 and z[i] < z[maxa]:
			print('YES')
			print(mini + 1, maxa + 1, i + 1)
			flag = 1
			break
		elif maxa != -1 and z[i] > z[maxa]:
			maxa = i
	if flag:
		continue
	else:
		print('NO')


import math
for _ in range(int(input())):
	n = int(input())
	A = list(map(int, input('').split()))
	index = dict()
	for i in range(n):
		index[A[i]] = i
	A.sort()
	flag = 0
	start = 0
	last = n - 1
	for i in range(n - 1, -1, -1):
		if last - start + 1 < 3:
			flag = 1
			break
		if index[A[i]] == last:
			last -= 1
			continue
		if index[A[i]] == start:
			start += 1
			continue
		break
	if flag == 1:
		print('NO')
	else:
		print('YES')
		print(start + 1, index[A[i]] + 1, last + 1)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	found = False
	for i in range(n):
		if found:
			break
		maxx = 0
		maxx_j = 0
		z = 0
		for j in range(i + 1, n):
			if found:
				break
			if a[j] > maxx and a[j] > a[i]:
				maxx = a[j]
				maxx_j = j
			if a[j] < maxx and maxx > 0 and (a[i] < maxx):
				print('YES')
				print(i + 1, maxx_j + 1, j + 1)
				found = True
	if not found:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list((int(i) for i in input().split()))
	ans = False
	j = 0
	for i in range(1, n - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			ans = True
			j = i
			break
	if ans:
		print('YES')
		print(str(j) + ' ' + str(j + 1) + ' ' + str(j + 2))
	else:
		print('NO')


import io
import os
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline

def get_str():
	return input().decode().strip()

def rint():
	return map(int, input().split())

def oint():
	return int(input())
t = oint()
for _ in range(t):
	n = oint()
	p = list(rint())
	for i in range(n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


n = int(input())
m = 0
while m < n:
	x = int(input())
	num_list = []
	num_list = list(map(int, input().split()))
	indicator = False
	ptr = 1
	while ptr < x - 1:
		if num_list[ptr] > num_list[ptr - 1] and num_list[ptr] > num_list[ptr + 1]:
			indicator = True
			i = ptr
			j = ptr + 1
			k = ptr + 2
			break
		else:
			ptr += 1
	if indicator:
		print('YES')
		print(i, j, k)
	else:
		print('NO')
	m += 1


t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(x) for x in input().split()]
	prev = a[0]
	previ = -1
	inc = False
	dec = False
	out = [n + 1, 0, n + 1]
	for (i, x) in enumerate(a[1:]):
		if x > prev:
			inc = True
			dec = False
		elif x < prev:
			dec = True
			inc = False
		else:
			(inc, dec) = (False, False)
		if inc:
			out[1] = i + 2
			out[0] = previ + 2
		elif dec:
			out[2] = i + 2
			if out[0] <= n:
				break
		prev = x
		previ = i
	else:
		print('NO')
		continue
	print('YES')
	print(' '.join(map(str, out)))


from itertools import permutations
from itertools import combinations
t = int(input())
for i in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	a = []
	c = True
	for i in range(n - 2):
		if l[i + 1] > l[i] and l[i + 1] > l[i + 2]:
			c = False
			print('YES')
			print(i + 1, i + 2, i + 3, end=' ')
			print(' ')
			break
	if c == True:
		print('NO')


import os
import sys
from math import *
from collections import *
from fractions import *
from bisect import *
from heapq import *
from io import BytesIO, IOBase

def vsInput():
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
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')

def value():
	return tuple(map(int, input().split()))

def array():
	return [int(i) for i in input().split()]

def Int():
	return int(input())

def Str():
	return input()

def arrayS():
	return [i for i in input().split()]
for _ in range(Int()):
	n = Int()
	a = array()
	i = 1
	mi = 0
	ans = -1
	found = False
	while i < n:
		if a[i] > a[mi]:
			for j in range(i + 1, n):
				if a[j] < a[i]:
					ans = (mi + 1, i + 1, j + 1)
					found = True
					break
			if found:
				break
		else:
			mi = i
		i += 1
	if ans != -1:
		print('YES')
		print(*ans)
	else:
		print('NO')


def func():
	nn = int(input())
	for _ in range(nn):
		n = int(input())
		values = list(map(int, input().split()))
		l = []
		for i in range(1, n - 1):
			(a, b, c) = (values[i - 1], values[i], values[i + 1])
			if a < b > c:
				print('YES')
				print(i, i + 1, i + 2)
				break
		else:
			print('NO')
func()


import os
import heapq
import sys
import math
import operator
from collections import defaultdict
from io import BytesIO, IOBase
sys.setrecursionlimit(10 ** 5)

def gcd(a, b):
	if b == 0:
		return a
	else:
		return gcd(b, a % b)

def inpt():
	return [int(k) for k in input().split()]

def main():
	for _ in range(int(input())):
		n = int(input())
		ar = inpt()
		ok = False
		for i in range(1, n - 1):
			if ar[i] > ar[i - 1] and ar[i] > ar[i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				ok = True
				break
		if not ok:
			print('NO')
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')
main()


t = int(input())
for test in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	flag = False
	for i in range(n - 2):
		a = arr[i]
		b = arr[i + 1]
		c = arr[i + 2]
		if a < b > c:
			print('Yes')
			print(i + 1, i + 1 + 1, i + 2 + 1)
			flag = True
			break
	if not flag:
		print('No')


for _ in range(int(input())):
	(n, p) = (int(input()), list(map(int, input().split())))
	biggerL = [-1] * n
	biggerR = [-1] * n
	(lLo, lLoI) = (p[0], 0)
	(rLo, rLoI) = (p[-1], n - 1)
	for i in range(1, n - 1):
		if p[i] > lLo:
			biggerL[i] = lLoI
		elif p[i] < lLo:
			lLo = p[i]
			lLoI = i
		if p[-i - 1] > rLo:
			biggerR[-i - 1] = rLoI
		elif p[-i - 1] < rLo:
			rLo = p[-i - 1]
			rLoI = n - i - 1
	for i in range(1, n - 1):
		if biggerL[i] > -1 and biggerR[i] > -1:
			print('YES')
			print(biggerL[i] + 1, i + 1, biggerR[i] + 1)
			break
	else:
		print('NO')


for q in range(int(input())):
	n = int(input())
	s = list(map(int, input().split()))
	flag = 0
	for i in range(1, n - 1):
		if s[i - 1] < s[i] and s[i] > s[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			flag = 1
			break
	if flag == 0:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	array = list(map(int, input().split()))
	i = n
	j = 0
	k = n - 1
	while i > 0 and j < n and (k > 0):
		if array[j] == i or array[k] == i:
			if array[j] == i:
				j = j + 1
			if array[k] == i:
				k = k - 1
			i = i - 1
		else:
			print('YES')
			print(array.index(i), array.index(i) + 1, array.index(i) + 2)
			break
	if i == 0 or j >= n or k <= 0:
		print('NO')


for i in range(int(input())):
	n = int(input())
	arr = list(map(int, input().split()))
	test = 0
	i = 1
	while i < len(arr) - 1:
		if arr[i - 1] < arr[i] and arr[i + 1] < arr[i]:
			test = 1
			print('YES')
			print(i, i + 1, i + 2)
			break
		i = i + 1
	if test == 0:
		print('NO')


for i in range(int(input())):
	n = int(input())
	m = [int(a) for a in input().split()]
	k = 0
	for j in range(n - 2):
		if m[j] < m[j + 1] and m[j + 1] > m[j + 2]:
			print('YES')
			print(j + 1, j + 2, j + 3)
			k += 1
			break
	if k == 0:
		print('NO')


def process(arr):
	n = len(arr)
	smallest_idx = 0
	for i in range(n):
		if smallest_idx != -1:
			for j in range(i + 1, n):
				if arr[j] < arr[i] > arr[smallest_idx]:
					return (smallest_idx, i, j)
		if arr[i] < arr[smallest_idx]:
			smallest_idx = i
	return None
for _ in range(int(input())):
	n = int(input())
	(*arr,) = map(int, input().split())
	ans = process(arr)
	if ans is None:
		print('NO')
	else:
		print('YES')
		print(*[v + 1 for v in ans])


class Main:

	def main(self):
		t = int(input())
		for t1 in range(0, t):
			input()
			p = list(map(int, input().split()))
			results = [1, 0, 0]
			for i in range(1, len(p)):
				if results[1] == 0:
					if p[results[0] - 1] > p[i]:
						results[0] = i + 1
					elif p[results[0] - 1] < p[i]:
						results[1] = i + 1
				elif p[results[1] - 1] < p[i]:
					results[1] = i + 1
				elif p[results[1] - 1] > p[i]:
					results[2] = i + 1
					break
			if results[0] < results[1] and results[1] < results[2]:
				print('YES')
				print(results[0], results[1], results[2])
			else:
				print('NO')
Main().main()


def main():
	(n,) = map(int, input().split(' '))
	a = list(map(int, input().split(' ')))
	i1 = 0
	for i in range(1, n):
		if i1 == 0 and a[i - 1] < a[i]:
			i1 = i
		if i1 > 0 and a[i - 1] > a[i]:
			print('YES')
			print(i1, i, i + 1)
			return
	print('NO')
for _ in range(int(input())):
	main()


import sys
(input, print) = (sys.stdin.readline, sys.stdout.write)
for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	b = a.copy()
	while a:
		if n == a[0]:
			a.pop(0)
			n -= 1
		elif n == a[-1]:
			a.pop(-1)
			n -= 1
		else:
			j = b.index(n)
			(i, k) = (j - 1, j + 1)
			break
	if n == 0:
		print('NO' + '\n')
	else:
		print('YES' + '\n')
		print(str(i + 1) + ' ' + str(j + 1) + ' ' + str(k + 1) + '\n')


s = int(input())
for a in range(s):
	h = int(input())
	t = list(map(int, input().split()))
	for c in range(1, h - 1):
		if t[c] > t[c - 1] and t[c] > t[c + 1]:
			print('YES')
			print(c, c + 1, c + 2)
			break
	else:
		print('NO')


from collections import defaultdict
for _ in range(int(input())):
	n = int(input())
	p = [int(_) for _ in input().split()]
	for i in range(n - 2):
		if p[i] < p[i + 2] < p[i + 1] or p[i + 2] < p[i] < p[i + 1]:
			print('YES')
			print(i + 1, i + 2, i + 3)
			break
	else:
		print('NO')


for t in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	index = a.index(max(a))
	arr = []
	pflag = 0
	nflag = 0
	if index == 0 or index == n - 1:
		for i in range(1, n):
			arr.append(a[i] - a[i - 1])
		for i in range(len(arr)):
			if pflag == 0:
				if arr[i] > 0:
					pflag = 1
					ans1 = i + 1
					ans2 = i + 2
			elif arr[i] < 0:
				nflag = 1
				ans3 = i + 2
				break
			else:
				ans1 = i + 1
				ans2 = i + 2
		if pflag == 1 and nflag == 1:
			print('YES')
			print(ans1, ans2, ans3)
		else:
			print('NO')
	else:
		print('YES')
		print(index, index + 1, index + 2)


import sys

def read():
	return [int(i) for i in sys.stdin.readline().strip().split()]
for i in range(int(input())):
	n = int(input())
	arr = read()
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


def check(a, n):
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			return True
	print('NO')
	return False
T = int(input())
for t in range(T):
	n = int(input())
	a = list(map(int, input().split()))
	check(a, n)


t = int(input())
for i in range(t):
	n = int(input())
	a = [int(i) for i in input().strip().split()]
	found = False
	for i in range(1, n - 1):
		if a[i - 1] < a[i] and a[i] > a[i + 1]:
			found = True
			print('YES')
			print(i, i + 1, i + 2)
			break
	if not found:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = [int(i) for i in input().split()]
	candidate = n
	while n != 0:
		l_num = -1
		r_num = -1
		ind = p.index(n)
		for l_ind in range(ind):
			if p[l_ind] < p[ind]:
				l_num = l_ind + 1
				break
		for r_ind in range(ind + 1, len(p)):
			if p[r_ind] < p[ind]:
				r_num = r_ind + 1
				break
		if l_num != -1 and r_num != -1:
			break
		else:
			n -= 1
	if n != 0:
		print('YES')
		print(l_num, ind + 1, r_num)
	else:
		print('NO')


t = input()
T = int(t)
id = 0
while id < T:
	s = input()
	a = input()
	arr = a.split(' ')
	n = int(s)
	ls = list()
	for b in arr:
		ls.append(int(b))
	i = 1
	while i < len(ls) - 1:
		if ls[i - 1] < ls[i] > ls[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
		i = i + 1
	if i == len(ls) - 1:
		print('NO')
	id = id + 1


for _ in range(int(input())):
	a = int(input())
	f = 0
	l = list(map(int, input().split()))
	for i in range(1, len(l) - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			f = 1
			break
	if f == 0:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	s = 'NO'
	for j in range(1, n - 1):
		if a[j] > a[j - 1] and a[j] > a[j + 1]:
			s = 'YES'
			print(s)
			print(j, j + 1, j + 2)
			break
	if s == 'NO':
		print(s)


t = int(input())
for tt in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	found = False
	for i in range(0, n - 2):
		for j in range(i + 1, n - 1):
			if a[j] > a[i] and a[j] > a[j + 1]:
				print('YES')
				print(i + 1, j + 1, j + 2)
				found = True
				break
		if found == True:
			break
	if found == False:
		print('NO')


t = int(input())
for k in range(t):
	n = int(input())
	a = [int(x) for x in input().split(' ')]
	q = -1
	w = -1
	mn = 0
	for i in range(1, n - 1):
		if a[i] > a[mn]:
			q = i
			break
		else:
			mn = i
	mn2 = n - 1
	for i in range(n - 2, 0, -1):
		if a[i] > a[mn2]:
			w = i
			break
		else:
			mn2 = i
	if q == -1 or w == -1 or q > w:
		print('NO')
	elif a[q] > a[w]:
		print('YES')
		print(mn + 1, q + 1, mn2 + 1)
	else:
		print('YES')
		print(mn + 1, w + 1, mn2 + 1)


for _ in range(int(input())):
	n = int(input())
	p = list((int(num) for num in input().split()))
	val = p[0]
	idxi = 0
	idxj = 0
	idxk = 0
	for z in range(1, n):
		if p[z] > val:
			idxj = z
			break
		else:
			val = p[z]
			idxi = z
	if idxj != 0:
		for x in range(z + 1, n):
			if p[x] >= p[idxj]:
				idxj = x
			else:
				idxk = x
				break
		if idxk != 0:
			print('YES')
			print(idxi + 1, idxj + 1, idxk + 1)
		else:
			print('NO')
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	P = list(map(int, input().split()))
	C = []
	for i in P:
		C.append(i)
	C.sort()
	if C == P or C[::-1] == P:
		print('NO')
	else:
		f = -1
		for i in range(1, n - 1):
			if P[i] > P[i - 1] and P[i] > P[i + 1]:
				f = 1
				print('YES')
				print(i, i + 1, i + 2)
				break
		if f == -1:
			print('NO')


from sys import stdin, stdout
T = int(stdin.readline())
for iT in range(T):
	stdin.readline()
	a = [int(i) for i in stdin.readline().split(' ') if i]
	for i in range(len(a) - 2):
		if a[i] < a[i + 1]:
			x = i
			break
	else:
		stdout.write('NO\n')
		continue
	for i in range(x + 1, len(a) - 1):
		if a[i] > a[i + 1]:
			stdout.write(f'YES\n{x + 1} {i + 1} {i + 2}\n')
			break
	else:
		stdout.write('NO\n')


t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	lst = []
	i = 1
	while i < n - 1:
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			lst.extend([i - 1, i, i + 1])
			i += 1
			break
		elif arr[i] > arr[i - 1] and arr[i] == arr[i + 1]:
			j = i
			i += 1
			while i < n - 1 and arr[j] == arr[i]:
				i += 1
			if arr[j] > arr[i]:
				lst.extend([j - 1, j, i])
				break
		else:
			i += 1
	if len(lst) == 0:
		print('NO')
	else:
		print('YES')
		print(lst[0] + 1, lst[1] + 1, lst[2] + 1)


from collections import defaultdict
for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	ans = 0
	for i in range(n - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			ans = (i + 1, i + 2, i + 3)
			break
	if ans == 0:
		print('NO')
	else:
		print('YES')
		print(*ans)


for i in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	pref = [10 ** 9]
	suf = [10 ** 9]
	for i in range(n):
		pref.append(min(pref[-1], a[i]))
	for i in range(n - 1, -1, -1):
		suf.append(min(suf[-1], a[i]))
	suf = suf[::-1]
	ans = -1
	for i in range(n):
		if a[i] > pref[i] and a[i] > suf[i + 1]:
			ans = i
			break
	if ans == -1:
		print('NO')
	else:
		print('YES')
		for i in range(n):
			if a[ans] > a[i]:
				print(i + 1, end=' ')
				break
		print(ans + 1, end=' ')
		for i in range(n - 1, -1, -1):
			if a[ans] > a[i]:
				print(i + 1, end=' ')
				break
		print()


def func():
	n = int(input())
	lst = list(map(int, input().split()))
	for i in range(1, n - 1):
		if lst[i] > lst[i - 1] and lst[i + 1] < lst[i]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
for __ in range(int(input())):
	func()


tcs = int(input())
result = []
for i in range(tcs):
	n = int(input())
	numbers = [int(s) for s in input().split(' ')]
	index = 0
	if n >= 3:
		for t in range(n - 2):
			if not (numbers[t + 1] > numbers[t + 2] and numbers[t + 1] > numbers[t]):
				continue
			else:
				index = t + 1
				break
		else:
			result.append((0, 0))
			continue
		result.append((1, index))
	else:
		result.append((0, 0))
for e in result:
	if e[0]:
		print('YES')
		print(str(e[1]), str(e[1] + 1), str(e[1] + 2))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	r = {}
	for i in range(n):
		flag = 0
		p2 = -1
		p3 = -1
		for j in range(i):
			if a[j] < a[i]:
				flag += 1
				p2 = j + 1
				break
		for j in range(i + 1, n):
			if a[j] < a[i]:
				flag += 1
				p3 = j + 1
				break
		if flag == 2:
			print('YES')
			print(p2, i + 1, p3)
			break
	if flag != 2:
		print('NO')


t = int(input())
for T in range(t):
	n = int(input())
	f = 0
	l = list(map(int, input().split()))
	for i in range(1, n - 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			p = i
			q = i + 1
			r = i + 2
			f = 1
			break
	if f == 0:
		print('NO')
	else:
		print('YES')
		print(p, q, r)


n = int(input())
perm_lst = []
for i in range(0, n):
	count = int(input())
	perm = input()
	perm = perm.split()
	a = [int(i) for i in perm]
	x = 0
	for i in range(0, len(a) - 2):
		if a[i] < a[i + 1] and a[i + 1] > a[i + 2]:
			x = x + 1
			print('YES')
			print(a.index(a[i]) + 1, a.index(a[i + 1]) + 1, a.index(a[i + 2]) + 1)
			break
		else:
			continue
	if x == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = [int(i) for i in input().split()]
	t = 'NO'
	for i in range(n - 2):
		if a[i] < a[i + 1] > a[i + 2]:
			t = 'YES'
			break
	print(t)
	if t == 'YES':
		print(i + 1, i + 2, i + 3)


n = int(input())

def checkConsecutive(l):
	return l == list(range(min(l), max(l) + 1))
for _ in range(n):
	throw = input()
	s = input()
	A = []
	s = s.split(' ')
	for x in s:
		A.append(int(x))
	biggest = max(A)
	B = A.copy()
	while A.index(biggest) in [0, len(A) - 1]:
		A.remove(biggest)
		if A == []:
			print('NO')
			break
		biggest = max(A)
	if A != []:
		print('YES')
		CC = [B.index(A[-1]) + 1, B.index(A[0]) + 1, B.index(biggest) + 1]
		CC.sort()
		print('{} {} {}'.format(str(CC[0]), str(CC[1]), str(CC[2])))


def ans(n, arr):
	for i in range(0, n - 2):
		if arr[i] < arr[i + 1] and arr[i + 2] < arr[i + 1]:
			print('YES')
			return '{} {} {}'.format(i + 1, i + 2, i + 3)
	return 'NO'
t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	print(ans(n, arr))


from bisect import bisect_left as bl
from bisect import bisect_right as br
from heapq import heappush, heappop
import math
from collections import *
from functools import reduce, cmp_to_key, lru_cache
import io, os
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
M = mod = 10 ** 9 + 7

def factors(n):
	return sorted(set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0))))

def inv_mod(n):
	return pow(n, mod - 2, mod)

def li():
	return [int(i) for i in input().rstrip().split()]

def st():
	return str(input().rstrip())[2:-1]

def val():
	return int(input().rstrip())

def li2():
	return [str(i)[2:-1] for i in input().rstrip().split()]

def li3():
	return [int(i) for i in st()]
for _ in range(val()):
	n = val()
	l = li()
	ans = 1
	mi = 0
	l1 = [n - 1]
	for i in range(n - 2, -1, -1):
		if l[l1[-1]] < l[i]:
			l1.append(l1[-1])
		else:
			l1.append(i)
	l1.reverse()
	mi = 0
	for i in range(1, n - 1):
		if l[mi] < l[i] and l[i] > l[l1[i + 1]]:
			print('YES')
			ans = 0
			print(mi + 1, i + 1, l1[i + 1] + 1)
			break
		if l[i] < l[mi]:
			mi = i
	if ans:
		print('No')


t = int(input())
cases = []
for i in range(t):
	input()
	cases.append(input().strip().split())

def solve(case):
	for i in range(len(case) - 2):
		j = i + 1
		k = i + 2
		if int(case[i]) < int(case[j]) and int(case[j]) > int(case[k]):
			print('YES')
			print(i + 1, i + 2, i + 3)
			return
	print('NO')
for case in cases:
	solve(case)


t = int(input().split()[0])
for case in range(t):
	n = int(input().split()[0])
	arr = list(map(int, input().split()))
	increase = False
	decrease = False
	first = -1
	second = -1
	third = -1
	middle = -1
	for i in range(1, n):
		if arr[i] > arr[i - 1]:
			increase = True
			first = i - 1
			second = i
			middle = arr[i]
		if arr[i] < middle and increase:
			decrease = True
			third = i
		if decrease:
			break
	if decrease:
		print('YES')
		print(str(first + 1) + ' ' + str(second + 1) + ' ' + str(third + 1))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = input().split(' ')
	for i in range(n):
		a[i] = int(a[i])
	firstind = -1
	i = 0
	while i < n - 1:
		if a[i] < a[i + 1]:
			firstind = i
			break
		i += 1
	secondind = -1
	while i < n - 1:
		if a[i + 1] < a[i]:
			secondind = i
			break
		i += 1
	thirdind = secondind + 1
	if min(firstind, secondind, thirdind) != -1:
		print('YES')
		print(firstind + 1, secondind + 1, thirdind + 1)
	else:
		print('NO')


T = int(input().rstrip())

def solve(arr):
	min_arr = [-1] * len(arr)
	min_arr_idx = [-1] * len(arr)
	min_idx = None
	curr_min = 100000
	for i in range(len(arr)):
		curr_val = arr[i]
		if curr_val < curr_min:
			curr_min = curr_val
			min_idx = i
		min_arr[i] = curr_min
		min_arr_idx[i] = min_idx
	min_rarr = [-1] * len(arr)
	min_rarr_idx = [-1] * len(arr)
	curr_rmin = 100000
	min_ridx = -1
	for i in range(len(arr) - 1, -1, -1):
		curr_val = arr[i]
		if curr_val < curr_rmin:
			curr_rmin = curr_val
			min_ridx = i
		min_rarr[i] = curr_rmin
		min_rarr_idx[i] = min_ridx
	for i in range(1, len(arr) - 1):
		cval = arr[i]
		if cval > min_arr[i - 1] and cval > min_rarr[i + 1]:
			print('YES')
			print(f'{min_arr_idx[i] + 1} {i + 1} {min_rarr_idx[i] + 1}')
			return
	print('NO')
	return
for test in range(T):
	n = int(input().rstrip())
	arr = [int(x) for x in input().rstrip().split()]
	solve(arr)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	i = 0
	j = 0
	k = 1
	while k < n and a[k] < a[j]:
		j += 1
		k += 1
	if j == n:
		print('NO')
	else:
		i = j
		while k < n and a[k] > a[j]:
			j += 1
			k += 1
		if k == n:
			print('NO')
		else:
			print('YES')
			print(i + 1, j + 1, k + 1)


for t in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	b = a[:]
	m = 2000
	q = 2000
	r = []
	l = []
	a.reverse()
	flag = 0
	for i in range(n):
		if m > a[i]:
			r.append(a[i])
			m = a[i]
		else:
			r.append(m)
		if q > b[i]:
			l.append(b[i])
			q = b[i]
		else:
			l.append(q)
	r.reverse()
	for i in range(1, n - 1):
		if b[i] > l[i - 1] and b[i] > r[i + 1]:
			flag = 1
			break
	if flag == 1:
		print('YES')
		print(b.index(l[i - 1]) + 1, i + 1, b.index(r[i + 1]) + 1)
	else:
		print('NO')


import bisect
import sys
import math
input = sys.stdin.readline
import functools
from collections import defaultdict

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())

def solve(case):
	n = inp()
	aa = inlt()
	minl = aa[:]
	minl[0] = 0
	minr = aa[:]
	minr[n - 1] = n - 1
	for i in range(1, n):
		if aa[i] < aa[minl[i - 1]]:
			minl[i] = i
		else:
			minl[i] = minl[i - 1]
	for i in range(n - 2, -1, -1):
		if aa[i] < aa[minr[i + 1]]:
			minr[i] = i
		else:
			minr[i] = minr[i + 1]
	for i in range(1, n - 1):
		if aa[i] > aa[minl[i - 1]] and aa[i] > aa[minr[i + 1]]:
			print('YES')
			print(str(minl[i - 1] + 1) + ' ' + str(i + 1) + ' ' + str(minr[i + 1] + 1))
			return None
	print('NO')
	return None
if len(sys.argv) > 1 and sys.argv[1].startswith('input'):
	f = open('./' + sys.argv[1], 'r')
	input = f.readline
T = inp()
for i in range(T):
	res = solve(i + 1)


t = int(input())
for hatt in range(t):
	n = int(input())
	p = [int(num) for num in input().split()]
	n1 = n
	n2 = 0
	incr = False
	decr = False
	for i in range(n - 1):
		if p[i] < p[i + 1]:
			n1 = min(i, n1)
			incr = True
		elif incr:
			n2 = i
			decr = True
			break
	if incr and decr:
		print('YES')
		print(n1 + 1, n2 + 1, n2 + 2)
	else:
		print('NO')


def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s)])

def invr():
	return map(int, input().split())

def solve():
	k = inp()
	l = inlt()
	a = l[0]
	ind_a = 0
	b = 0
	ind_b = 0
	c = 0
	ind_c = 0
	for i in range(k):
		if l[i] < a and c == 0 and (b == 0):
			a = l[i]
			ind_a = i
		elif l[i] > a and c == 0 and (l[i] > b):
			b = l[i]
			ind_b = i
		if l[i] < b:
			c = l[i]
			ind_c = i
	if ind_c != 0:
		print('YES')
		print(str(ind_a + 1) + ' ' + str(ind_b + 1) + ' ' + str(ind_c + 1))
	else:
		print('NO')
n = inp()
for _ in range(n):
	solve()


import os
import sys, math
from io import BytesIO, IOBase

def main():
	t = int(input())
	for case in range(t):
		n = int(input())
		l = list(map(int, input().split()))
		pre = [-1 for i in range(n)]
		post = [-1 for i in range(n)]
		ix = -1
		for i in range(n):
			if ix == -1 or l[i] < l[ix]:
				ix = i
			pre[i] = ix
		ix = -1
		for i in range(n - 1, -1, -1):
			if ix == -1 or l[i] < l[ix]:
				ix = i
			post[i] = ix
		ans = -1
		for i in range(n):
			if pre[i] != i and post[i] != i:
				ans = i
				break
		if ans == -1:
			print('NO')
		else:
			print('YES')
			print(pre[ans] + 1, ans + 1, post[ans] + 1)
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')
main()


import sys
t = int(input())
for k in range(t):
	n = int(input())
	arr = list(map(int, input().rstrip().split()))
	bool = False
	left = [0] * n
	right = [0] * n
	left[0] = [sys.maxsize, 0]
	minn = [sys.maxsize, 0]
	for i in range(1, n):
		if minn[0] > arr[i - 1]:
			minn = [arr[i - 1], i - 1]
		left[i] = minn
	right[n - 1] = [sys.maxsize, n - 1]
	minn = [sys.maxsize, n - 1]
	for i in range(len(arr) - 2, -1, -1):
		if minn[0] > arr[i + 1]:
			minn = [arr[i + 1], i + 1]
		right[i] = minn
	for i in range(1, len(arr) - 1):
		if left[i][0] < arr[i] and right[i][0] < arr[i]:
			print('YES')
			print(str(left[i][1] + 1) + ' ' + str(i + 1) + ' ' + str(right[i][1] + 1))
			bool = True
			break
	if bool == False:
		print('NO')


import sys
ii = lambda : sys.stdin.readline().strip()
idata = lambda : [int(x) for x in ii().split()]

def solve():
	n = int(ii())
	data = idata()
	(f, ans) = (True, False)
	for i in range(1, n):
		if data[i] > data[i - 1] and f:
			f = False
		elif data[i] < data[i - 1] and (not f):
			ans = True
	if ans:
		print('YES')
		for i in range(1, n - 1):
			if data[i - 1] < data[i] and data[i] > data[i + 1]:
				print(i, i + 1, i + 2)
				return
	print('NO')
	return
for t in range(int(ii())):
	solve()


def panda(n, l):
	for i in range(1, n - 1):
		if l[i + 1] < l[i] and l[i - 1] < l[i]:
			print('YES')
			print(i, i + 1, i + 2)
			return
	print('NO')
for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	panda(n, l)


t = int(input())
for _ in range(t):
	n = int(input())
	nums = [int(i) for i in input().split()]
	(i, j, k) = (-1, -1, -1)
	for x in range(n):
		if i == -1:
			i = x
		elif j == -1:
			if nums[x] > nums[i]:
				j = x
			else:
				i = x
		elif nums[x] > nums[j]:
			j = x
		else:
			k = x
			break
	if k == -1:
		print('NO')
	else:
		print('YES')
		print(i + 1, j + 1, k + 1)


from sys import *
input = stdin.readline
t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	c = 0
	for i in range(1, n - 1):
		if l[i] > l[i + 1] and l[i] > l[i - 1]:
			c = -1
			print('YES')
			print(i, i + 1, i + 2)
			break
	if c == 0:
		print('NO')


t = int(input())
for w in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	c = l.copy()
	for o in range(n - 1):
		g = max(c)
		if g == int(c[0]):
			del c[0]
		if g == int(c[-1]):
			del c[-1]
	if len(c) < 3:
		print('NO')
	else:
		print('YES')
		i = l.index(c[0]) + 1
		j = l.index(g) + 1
		k = l.index(c[-1]) + 1
		print(i, j, k)


for _ in range(int(input())):
	n = int(input())
	p = [int(i) for i in input().split()]
	ind1 = 0
	ind2 = 0
	ind3 = 0
	for i in range(1, len(p) - 1):
		a = p[:i]
		c = p[i + 1:]
		ma = min(a)
		mc = min(c)
		if ma < p[i] and p[i] > mc:
			ind1 = p.index(ma)
			ind3 = p.index(mc)
			ind2 = i
	if ind3 != 0:
		print('YES')
		print(ind1 + 1, ind2 + 1, ind3 + 1)
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	p = list(map(int, input().split()))
	for i in range(1, n - 1):
		if p[i - 1] < p[i] and p[i] > p[i + 1]:
			print('Yes')
			print(i, i + 1, i + 2)
			break
	else:
		print('No')


t = int(input())
for x in range(t):
	n = int(input())
	l1 = [int(x) for x in input().split()]
	done = 0
	for x in range(1, n + 1):
		c = [l1.index(x) + 1]
		left = l1[:l1.index(x)]
		for y in left:
			if y < x:
				c.append(l1.index(y) + 1)
				break
		right = l1[1 + l1.index(x):]
		for y in right:
			if y < x:
				c.append(l1.index(y) + 1)
				break
		if len(c) == 3:
			done = 1
			print('YES')
			c.sort()
			print(*c)
			break
	if not done:
		print('NO')


def achar_triade(numeros):
	for i in range(len(numeros) - 2):
		if numeros[i] < numeros[i + 1] and numeros[i + 1] > numeros[i + 2]:
			return (i + 1, i + 2, i + 3)

def main():
	n_testes = int(input())
	for i in range(n_testes):
		quantidade = int(input())
		numeros = input()
		numeros = numeros.split()
		numeros = list(map(lambda x: int(x), numeros))
		resposta = achar_triade(numeros)
		if resposta != None:
			print('YES')
			print(resposta[0], resposta[1], resposta[2])
		else:
			print('NO')
main()


T = int(input())
for _ in range(T):
	n = int(input())
	p = list(map(int, input().split()))
	mini_before = [int(n + 1) for _ in range(n)]
	mini_after = [int(n + 1) for _ in range(n)]
	for i in range(1, n):
		mini_before[i] = min(mini_before[i - 1], p[i - 1])
		mini_after[n - i - 1] = min(mini_after[n - i], p[n - i])
	ans = None
	for i in range(n):
		if p[i] > mini_before[i] and p[i] > mini_after[i]:
			before_idx = p.index(mini_before[i]) + 1
			after_idx = p.index(mini_after[i]) + 1
			current_idx = i + 1
			ans = [before_idx, current_idx, after_idx]
	if ans is not None:
		print('YES')
		print(' '.join(map(str, ans)))
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	a = p.copy()
	while a:
		if n == a[0]:
			a.pop(0)
			n -= 1
		elif n == a[-1]:
			a.pop(-1)
			n -= 1
		else:
			idx = p.index(n) + 1
			break
	if n == 0:
		print('NO')
	else:
		print('YES')
		print(idx - 1, idx, idx + 1)


import sys
I = sys.stdin.readline
pr = sys.stdout.write

def solve(n, ar):
	for x in range(1, n - 1):
		if ar[x] == max(ar[x - 1], ar[x], ar[x + 1]):
			pr(f'YES\n{x} {x + 1} {x + 2}\n')
			return
	pr('NO\n')

def main():
	for _ in range(int(I())):
		n = int(I())
		ar = list(map(int, I().split()))
		solve(n, ar)
main()


for _ in range(int(input())):
	(N, X, Check) = (int(input()), list(map(int, input().split())), True)
	for i in range(1, N - 1):
		if X[i - 1] < X[i] > X[i + 1]:
			print('YES\n', i, i + 1, i + 2)
			Check = False
			break
	if Check:
		print('NO')


def main():
	t = int(input())
	d = [[int(input()), [int(x) for x in input().split()]] for i in range(t)]
	s = True
	for c in d:
		s = True
		for i in range(1, c[0] - 1):
			if c[1][i - 1] < c[1][i] and c[1][i] > c[1][i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				s = False
				break
		if s:
			print('NO')
main()


def solve(arr):
	for j in range(1, n - 1):
		if arr[j] > arr[j - 1] and arr[j] > arr[j + 1]:
			print('YES')
			print('{} {} {}'.format(j, j + 1, j + 2))
			return
	print('NO')
	return
t = int(input())
for _ in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	solve(arr)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	b = sorted(a)
	(i, j) = (0, n)
	while j - i > 2:
		if b[-1] == a[j - 1]:
			b.pop()
			j -= 1
		elif b[-1] == a[i]:
			i += 1
			b.pop()
		else:
			print('YES')
			print(i + 1, a.index(b[-1]) + 1, j)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	flag = False
	for j in range(1, n - 1):
		i = j - 1
		k = j + 1
		if a[i] < a[j] and a[k] < a[j]:
			print('YES')
			print(i + 1, j + 1, k + 1)
			flag = True
			break
	if not flag:
		print('NO')


import math
for _ in range(int(input())):
	n = int(input())
	c = 0
	z = []
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			c = 1
			z.append(i)
			z.append(i + 1)
			z.append(i + 2)
			break
	if c == 1:
		print('YES')
		print(*z)
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	indices = [0, 0, 0]
	p = [int(x) for x in input().split()]
	for i in range(1, len(p)):
		if indices[1] == 0:
			if p[i - 1] < p[i]:
				indices[0] = i
				indices[1] = i + 1
		elif p[i - 1] < p[i]:
			indices[1] = i + 1
		elif p[i - 1] > p[i]:
			indices[2] = i + 1
			break
	if indices[2] == 0:
		print('NO')
	else:
		print('YES')
		print(*indices)


for _ in range(int(input())):
	n = int(input())
	data = list(map(int, input().split()))
	i = 0
	j = n - 1
	found = False
	while not found and i < j:
		if data[i] == n:
			n -= 1
			i += 1
		elif data[j] == n:
			n -= 1
			j -= 1
		else:
			found = True
	if found:
		print('YES')
		print(i + 1, data.index(n) + 1, j + 1)
	else:
		print('NO')


for tc in range(int(input())):
	n = int(input())
	A = input().split(' ')
	for i in range(n):
		A[i] = int(A[i])
	ind = 0
	for i in range(1, n - 1):
		if A[i] > A[i - 1] and A[i] > A[i + 1]:
			ind = i
			break
	if ind == 0:
		print('NO')
	else:
		print('YES')
		print(ind, ind + 1, ind + 2)


def main():
	for _ in range(int(input())):
		n = int(input())
		check = n
		arr = list(map(int, input().split()))
		i = 1
		k = n
		while check != 1:
			if arr[i - 1] == check:
				check -= 1
				i += 1
			elif arr[k - 1] == check:
				check -= 1
				k -= 1
			else:
				j = arr.index(check)
				print('YES')
				print(i, j + 1, k)
				break
		if check == 1:
			print('NO')
		else:
			continue
main()


from __future__ import division, print_function
import itertools, os, sys, threading
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
	from __builtin__ import xrange as range
	from future_builtins import ascii, filter, hex, map, oct, zip
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')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
from math import sqrt, floor, factorial, gcd, log
from collections import deque, Counter, defaultdict
from itertools import permutations, combinations
from math import gcd
from bisect import bisect
from random import randrange
input = lambda : sys.stdin.readline().rstrip('\r\n')
read = lambda : list(map(int, input().strip().split(' ')))

def main():
	for _ in range(int(input())):
		n = int(input())
		arr = read()
		arr2 = list(zip(arr, range(1, n + 1)))
		arr2.sort()
		f = 1
		mini = maxi = arr2[0][1]
		for i in range(1, n):
			if mini < arr2[i][1] < maxi:
				print('YES')
				print(mini, arr2[i][1], maxi)
				f = 0
				break
			mini = min(mini, arr2[i][1])
			maxi = max(maxi, arr2[i][1])
		if f:
			print('NO')
main()


for t in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	a1 = 0
	a2 = 0
	a3 = 0
	ch = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			a1 = i
			a2 = i + 1
			a3 = i + 2
			ch = 1
	if ch == 1:
		print('YES')
		print(a1, a2, a3)
	else:
		print('NO')


from sys import stdin
t = int(stdin.readline().strip())
for i in range(t):
	n = int(stdin.readline().strip())
	P = list(map(int, stdin.readline().strip().split(' ')))
	i = 0
	j = n - 1
	isPossible = False
	while i < j:
		if P[i] == n:
			i += 1
			n -= 1
		elif P[j] == n:
			j -= 1
			n -= 1
		else:
			isPossible = True
			print('YES')
			print(i + 1, P.index(n) + 1, j + 1)
			break
	if not isPossible:
		print('NO')


n = int(input())
for i in range(0, n):
	x = int(input())
	y = list(map(int, input().split()))
	z = [0] * x
	for j in range(0, x):
		z[j] = y[j]
	y.sort()
	count = 0
	small = 0
	large = 0
	a = 0
	b = 0
	c = 0
	for j in range(0, x):
		if y[j] != j + 1:
			count += 1
			break
	if count > 0:
		print('NOpe')
	else:
		for j in range(1, x):
			a = 0
			b = j
			small = 0
			large = 0
			while a < j:
				if z[a] < z[j]:
					small = 1
					break
				a += 1
			while b < x:
				if z[b] < z[j]:
					large = 1
					break
				b += 1
			if small == 1 and large == 1:
				c = j
				break
		if small == 0 or large == 0:
			print('NO')
		else:
			print('YES')
			print(a + 1, c + 1, b + 1)


def ans_f(a):
	n = len(a)
	p = n
	l = 0
	r = n - 1
	while p >= 3:
		if a[l] != n and a[r] != n:
			j = a.index(n) + 1
			i = a.index(n)
			k = a.index(n) + 2
			return ['YES', i, j, k]
		else:
			if a.index(n) == l:
				l = l + 1
			else:
				r = r - 1
			p -= 1
			n = n - 1
	return 'NO'
t = int(input())
ans = []
for i in range(t):
	n = int(input())
	a = [int(i) for i in input().split()]
	ans.append(ans_f(a))
for i in ans:
	if type(i) == str:
		print(i)
	else:
		print(i[0])
		print(*i[1:])


import random

def gcd(a, b):
	if a == 0:
		return b
	return gcd(b % a, a)

def lcm(a, b):
	return a * b / gcd(a, b)
for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	d = [[-1]]
	min_now = p[0]
	min_ind = 0
	for i in range(1, n):
		if p[i] < min_now:
			d.append([-1])
			min_now = p[i]
			min_ind = i
		else:
			d.append([min_ind])
	d[n - 1].append(-1)
	min_now = p[n - 1]
	min_ind = n - 1
	for i in range(n - 2, -1, -1):
		if p[i] < min_now:
			d[i].append(-1)
			min_now = p[i]
			min_ind = i
		else:
			d[i].append(min_ind)
	f = 0
	for i in range(n):
		if d[i][0] != -1 and d[i][1] != -1:
			f = 1
			print('YES')
			print(d[i][0] + 1, i + 1, d[i][1] + 1)
			break
	if not f:
		print('NO')


ll = lambda : list(map(int, input().split()))
st = lambda : input()
v = lambda : map(int, input().split())
ii = lambda : int(input())
from collections import *
from math import *
from datetime import datetime

def gcd(a, b):
	if a == 0:
		return b
	return gcd(b % a, a)

def lcm(a, b):
	return a * b / gcd(a, b)
for _ in range(ii()):
	n = ii()
	l = ll()
	p = l[0]
	f = 0
	for i in range(1, n - 1):
		if l[i - 1] < l[i] > l[i + 1]:
			f = 1
			(x, y, z) = (i - 1, i, i + 1)
			break
	if f == 0:
		print('NO')
		continue
	print('YES')
	print(x + 1, y + 1, z + 1)


t = int(input())
for _ in range(t):
	n = int(input())
	a = [int(d) for d in input().split()]
	flag = 0
	if a[1] - a[0] > 0:
		inc = True
		dec = False
	else:
		dec = True
		inc = False
	i1 = 0
	i2 = 0
	i3 = 0
	for i in range(1, n):
		if inc == True:
			if a[i] - a[i - 1] < 0:
				i2 = i - 1
				i3 = i
				flag = 1
				print('YES')
				print(i1 + 1, i2 + 1, i3 + 1)
				break
			else:
				continue
		if dec == True:
			if a[i] - a[i - 1] > 0:
				inc = True
				dec = False
				i1 = i - 1
			else:
				continue
	if flag == 0:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	arr = list(map(int, input().split()))
	(a, b, c) = (0, 0, 0)
	flag = 0
	for j in range(1, n - 1):
		if arr[j - 1] < arr[j] and arr[j] > arr[j + 1]:
			flag = 1
			a = j
			b = j + 1
			c = j + 2
			break
	if flag == 0:
		print('NO')
	else:
		print('YES')
		print(a, b, c)


for n in range(int(input())):
	T = int(input())
	P = list(map(int, input().split()))
	for t in range(T - 2):
		if P[t] < P[t + 1] and P[t + 1] > P[t + 2]:
			print('YES')
			print(f'{t + 1} {t + 2} {t + 3}')
			break
	else:
		print('NO')


def solve(a, n):
	minr = [n - 1] * n
	for i in range(n - 2, -1, -1):
		best = minr[i + 1]
		if a[i] < a[best]:
			best = i
		minr[i] = best
	minl = 0
	for i in range(1, n - 1):
		if a[i] > a[minl]:
			if a[i] > a[minr[i + 1]]:
				return (minl + 1, i + 1, minr[i + 1] + 1)
		else:
			minl = i
	return None
tests = int(input())
for test in range(tests):
	n = int(input())
	a = list(map(int, input().split()))
	ans = solve(a, n)
	if ans is None:
		print('NO')
	else:
		print('YES')
		print(*ans)


for run in range(int(input())):
	n = int(input())
	lst = list(map(int, input().split()))
	found = False
	for i in range(1, n - 1):
		if lst[i] > lst[i - 1] and lst[i] > lst[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			found = True
			break
	if found == False:
		print('NO')


t = int(input())
for _ in range(t):
	cnt = int(input())
	p = list(map(int, input().split()))
	for i in range(1, cnt - 1):
		if p[i] > p[i - 1] and p[i] > p[i + 1]:
			print('YES')
			print(f'{i} {i + 1} {i + 2}')
			break
	else:
		print('NO')


import os, io
from sys import stdout
import collections
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
import sys

def primes(n):
	sieve = [True] * n
	for i in range(3, int(n ** 0.5) + 1, 2):
		if sieve[i]:
			sieve[i * i::2 * i] = [False] * ((n - i * i - 1) // (2 * i) + 1)
	return [2] + [i for i in range(3, n, 2) if sieve[i]]

def binomial_coefficient(n, k):
	if 0 <= k <= n:
		ntok = 1
		ktok = 1
		for t in range(1, min(k, n - k) + 1):
			ntok *= n
			ktok *= t
			n -= 1
		return ntok // ktok
	else:
		return 0

def powerOfK(k, max):
	if k == 1:
		return [1]
	if k == -1:
		return [-1, 1]
	result = []
	n = 1
	while n <= max:
		result.append(n)
		n *= k
	return result

def divisors(n):
	i = 1
	result = []
	while i * i <= n:
		if n % i == 0:
			if n / i == i:
				result.append(i)
			else:
				result.append(i)
				result.append(n / i)
		i += 1
	return result

def distance(xa, ya, xb, yb):
	return ((ya - yb) ** 2 + (xa - xb) ** 2) ** 0.5

def digitsSum(n):
	if n == 0:
		return 0
	r = 0
	while n > 0:
		r += n % 10
		n //= 10
	return r

def isValid(i, j, n, m):
	return i >= 0 and i < n and (j >= 0) and (j < m)

def print_grid(grid):
	for line in grid:
		print(' '.join(map(str, line)))

def kadane(a, size):
	max_so_far = 0
	max_ending_here = 0
	for i in range(0, size):
		max_ending_here = max_ending_here + a[i]
		if max_so_far < max_ending_here:
			max_so_far = max_ending_here
		if max_ending_here < 0:
			max_ending_here = 0
	return max_so_far

def prefixSum(arr):
	for i in range(1, len(arr)):
		arr[i] = arr[i] + arr[i - 1]
	return arr

def ceil(n, d):
	if n % d == 0:
		return n // d
	else:
		return n // d + 1

def _abs(a, b):
	return int(abs(a - b))

def evenodd(l):
	even = [e for e in l if e & 1 == 0]
	odd = [e for e in l if e & 1]
	return (even, odd)
t = int(input())
for _ in range(t):
	n = int(input())
	l = list(map(int, input().split()))
	m = max(l)
	left = [m] * len(l)
	right = [m] * len(l)
	for i in range(1, len(l)):
		left[i] = min(left[i - 1], l[i - 1])
	for i in range(len(l) - 2, -1, -1):
		right[i] = min(right[i + 1], l[i + 1])
	done = False
	for i in range(1, len(l) - 1):
		if l[i] > left[i] and l[i] > right[i]:
			a = l.index(left[i])
			b = l.index(right[i])
			print('YES')
			print(a + 1, i + 1, b + 1)
			done = True
			break
	if not done:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	li = list(map(int, input().split()))
	c = 0
	for i in range(n - 2):
		if li[i + 1] > li[i] and li[i + 1] > li[i + 2]:
			print('Yes')
			print(i + 1, i + 2, i + 3)
			c = 1
			break
	if c == 0:
		print('No')


t = int(input())
for _ in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	j = -1
	p = []
	for i in range(1, n):
		if a[i] > a[i - 1]:
			p.append(1)
		else:
			p.append(-1)
	for i in range(1, n - 1):
		if p[i - 1] == 1 and p[i] == -1:
			j = i
	if j == -1:
		print('NO')
	else:
		print('YES')
		print(j, j + 1, j + 2)


for _ in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	b = []
	if n < 3:
		print('NO')
	b.append(a[0])
	for i in range(1, n):
		if len(b) == 1:
			if a[i] < b[-1]:
				b.pop()
				b.append(a[i])
			else:
				b.append(a[i])
		elif len(b) == 2:
			if a[i] < b[-1]:
				b.append(a[i])
				break
			else:
				b.pop()
				b.append(a[i])
	if len(b) == 3:
		print('YES')
		for i in range(3):
			print(a.index(b[i]) + 1, end=' ')
		print()
	else:
		print('NO')


t = int(input())
answer = []
for i in range(t):
	work = False
	n = int(input())
	lst = [int(x) for x in input().split()]
	for j in range(1, n - 1):
		if lst[j - 1] < lst[j] and lst[j] > lst[j + 1]:
			work = True
			answer.append(['YES'])
			answer.append([j, j + 1, j + 2])
			break
	if not work:
		answer.append(['NO'])
for i in range(len(answer)):
	for j in range(len(answer[i])):
		print(answer[i][j], end=' ')
	print()


import sys
import math
from collections import defaultdict

def main():
	n = int(input())
	arr = list(map(int, input().split()))
	pre = [arr[0]]
	for i in range(1, n):
		pre.append(min(arr[i], pre[-1]))
	post = [arr[-1]]
	for i in range(n - 1, -1, -1):
		post.append(min(arr[i], post[-1]))
	post.reverse()
	a = b = c = -1
	for i in range(1, n - 1):
		if arr[i] > pre[i - 1] and arr[i] > post[i + 1]:
			a = pre[i - 1]
			b = arr[i]
			c = post[i + 1]
			break
	if a != -1:
		print('YES')
		print(arr.index(a) + 1, arr.index(b) + 1, arr.index(c) + 1)
	else:
		print('NO')
for i in range(int(input())):
	main()


numberOfTc = int(input())
for ctr in range(1, numberOfTc + 1):
	n = int(input())
	lis = list(map(int, input().split()))
	f = 0
	for i in range(1, n - 1):
		if lis[i] > lis[i - 1] and lis[i] > lis[i + 1]:
			a = i
			b = i + 1
			c = i + 2
			f = 1
			break
	if f:
		print('YES')
		print(a, b, c)
	else:
		print('NO')


for _ in range(int(input())):
	size = int(input())
	arr = list(map(int, input().split()))
	found = 0
	for i in range(1, size - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			found = 1
			break
	if found == 0:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	mass = list(map(int, input().split()))
	ans = []
	b = False
	for i in range(1, n - 1):
		if mass[i - 1] < mass[i] and mass[i] > mass[i + 1]:
			b = True
			ans.append(i)
			ans.append(i + 1)
			ans.append(i + 2)
			break
	if b:
		print('YES')
		print(*ans)
	else:
		print('NO')


import sys
import collections

def input():
	return sys.stdin.readline().rstrip()

def split_input():
	return [int(i) for i in input().split()]
tests = int(input())
for _ in range(tests):
	n = int(input())
	a = split_input()
	ans = True
	for i in range(n):
		if a[i] != i + 1:
			ans = False
			break
	if ans:
		print('NO')
		continue
	ind = 1
	while ind < n and a[ind] < a[ind - 1]:
		ind += 1
	if ind == n:
		print('NO')
		continue
	while ind < n and a[ind] > a[ind - 1]:
		ind += 1
	if ind == n:
		print('NO')
		continue
	print('YES')
	print(ind - 1, ind, ind + 1)


for _ in range(int(input())):
	n = int(input())
	fg = 0
	a = list(map(int, input().split()))
	for x in range(1, n - 1):
		if a[x] > a[x - 1] and a[x] > a[x + 1]:
			fg = 1
			print('YES')
			print(x, x + 1, x + 2)
			break
	if fg == 0:
		print('NO')


import sys
import math
from functools import reduce
import bisect

def getN():
	return int(input())

def getNM():
	return map(int, input().split())

def getList():
	return list(map(int, input().split()))

def input():
	return sys.stdin.readline().rstrip()

def index(a, x):
	i = bisect.bisect_left(a, x)
	if i != len(a) and a[i] == x:
		return i
	return False
for _ in range(int(input())):
	n = getN()
	arr = getList()
	for i in range(1, n - 1):
		if arr[i - 1] < arr[i] and arr[i] > arr[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


tt = int(input())
for t in range(tt):
	x = True
	n = int(input())
	arr = list(map(int, input().split()))
	for i in reversed(range(1, n + 1)):
		if arr.index(i) != n - 1 and arr.index(i) != 0 and (x == True):
			if arr[arr.index(i) - 1] < arr[arr.index(i)] and arr[arr.index(i)] > arr[arr.index(i) + 1]:
				print('YES')
				print(arr.index(i), arr.index(i) + 1, arr.index(i) + 2)
				x = False
				break
	if x == True:
		print('NO')


a = int(input())
arrays = []
for i in range(a):
	tmp = input()
	array = list(map(int, input().split()))
	arrays.append(array)
for arr in arrays:
	save_i = -1
	save_j = -1
	save_k = -1
	for i in range(1, len(arr) - 1):
		if arr[i] > arr[i + 1] and arr[i] > arr[i - 1]:
			save_i = i - 1
			save_j = i
			save_k = i + 1
	if save_i != -1 and save_j != -1 and (save_k != -1):
		print('YES')
		print(save_i + 1, save_j + 1, save_k + 1)
	else:
		print('NO')


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	n = int(input())
	L = list(map(int, input().split()))
	for i in range(n - 1):
		if L[i] < L[i + 1]:
			break
	k = -1
	for j in range(i + 1, n - 1):
		if L[j] > L[j + 1]:
			k = j + 1
			break
	if k == -1:
		print('NO')
	else:
		print('YES')
		print(i + 1, j + 1, k + 1)


import sys, math
input = lambda : sys.stdin.readline().rstrip()
for i in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	ans = True
	for j in range(1, n - 1):
		if p[j - 1] < p[j] and p[j] > p[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			ans = False
			break
	if ans:
		print('NO')


def solve(n, arr, arrDeep):
	if n < 3:
		return 'NO'
	if n != arr[0] and n != arr[-1]:
		b = arrDeep.index(max(arr))
		a = b - 1
		c = b + 1
		return [a + 1, b + 1, c + 1]
	else:
		if n == arr[-1]:
			arr.pop()
		else:
			arr.pop(0)
		a = solve(n - 1, list(arr), arrDeep)
		return a

def main():
	n = int(input())
	while n > 0:
		t = int(input())
		arr = [int(x) for x in input().split()]
		ans = solve(t, arr, list(arr))
		if ans == 'NO':
			print('NO')
		else:
			print('YES')
			for c in ans:
				print(c, end=' ')
		n -= 1
main()


from sys import stdin
inp = lambda : stdin.readline().strip()
t = int(inp())
for _ in range(t):
	n = int(inp())
	a = [int(x) for x in inp().split()]
	flag = False
	x = -1
	for i in range(n):
		for j in range(i - 1, -1, -1):
			if a[j] < a[i]:
				x = j
				for k in range(i + 1, n, 1):
					if a[k] < a[i]:
						print('YES')
						print(j + 1, i + 1, k + 1)
						flag = True
						break
				break
		if flag:
			break
	if not flag:
		print('NO')


import math
t = int(input())
for _ in range(t):
	n = int(input())
	k = z = p = 0
	m = 10 ** 9
	bool = True
	l = list(map(int, input().split()))
	for i in range(1, n - 1):
		m = min(m, l[i - 1])
		if l[i] > m and l[i] > min(l[i + 1:n]):
			p = i
			k = l.index(m)
			z = l.index(min(l[i + 1:n]))
			print('YES')
			bool = False
			break
	if not bool:
		print(k + 1, end=' ')
		print(p + 1, end=' ')
		print(z + 1)
	else:
		print('NO')


import sys
t = int(input())
for i in range(1, t + 1):
	c = 0
	n = int(input())
	p = list(map(int, input().split()))
	for j in range(1, n - 1):
		if p[j - 1] < p[j] and p[j] > p[j + 1]:
			print('YES')
			print(j, j + 1, j + 2)
			c = 1
			break
	if c == 0:
		print('NO')
exit(0)


T = int(input())
for _ in range(T):
	n = int(input())
	p = list(map(int, input().split()))
	for j in range(1, n - 1):
		left = min(p[:j])
		right = min(p[j + 1:])
		result = []
		if p[j] > left and p[j] > right:
			result.append(p.index(left) + 1)
			result.append(j + 1)
			result.append(p.index(right) + 1)
			break
		else:
			continue
	if len(result) == 0:
		print('NO')
	else:
		print('YES')
		for i in result:
			print(i, end=' ')
		print()


def ThreeIndices(n, p):
	for l in range(n):
		if l + 2 <= n - 1:
			if p[l] < p[l + 1] and p[l + 1] > p[l + 2]:
				return 'YES\n' + str(l + 1) + ' ' + str(l + 2) + ' ' + str(l + 3)
	return 'NO'
Lista = []
total = int(input())
for i in range(total * 2):
	All = [int(i) for i in input().split()]
	Lista.append(All)
for j in range(0, len(Lista), 2):
	print(ThreeIndices(Lista[j][0], Lista[j + 1]))


def foo():
	n = int(input())
	l = [int(x) for x in input().split()]
	for i in range(1, n - 1):
		if l[i] > l[i - 1] and l[i] > l[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')
for _ in range(int(input())):
	foo()


import sys

def rs():
	return sys.stdin.readline().rstrip()

def ri():
	return int(sys.stdin.readline())

def ria():
	return list(map(int, sys.stdin.readline().split()))

def ws(s):
	sys.stdout.write(s)
	sys.stdout.write('\n')

def wi(n):
	sys.stdout.write(str(n))
	sys.stdout.write('\n')

def wia(a, sep=' '):
	sys.stdout.write(sep.join([str(x) for x in a]))
	sys.stdout.write('\n')

def solve(n, a):
	i = 0
	while i < n - 1 and a[i] > a[i + 1]:
		i += 1
	k = n - 1
	while k > 1 and a[k] > a[k - 1]:
		k -= 1
	if k > i + 1:
		for j in range(i + 1, k):
			if a[j] > a[i] and a[j] > a[k]:
				break
		ws('YES')
		wia([i + 1, j + 1, k + 1])
	else:
		ws('NO')

def main():
	for _ in range(ri()):
		n = ri()
		a = ria()
		solve(n, a)
main()


for _ in range(int(input())):
	n = int(input())
	L1 = list(map(int, input().split()))
	L = list(L1)
	for j in range(len(L)):
		M = max(L)
		ind = L.index(M)
		if not (ind == len(L) - 1 or ind == 0):
			print('YES')
			print(L1.index(L[ind - 1]) + 1, L1.index(L[ind]) + 1, L1.index(L[ind + 1]) + 1)
			break
		else:
			del L[ind]
			if len(L) == 0:
				print('NO')
				break


t = int(input())
for i in range(t):
	n = int(input())
	s = input()
	r = [int(s) for s in s.split()]
	f = 0
	for j in range(1, n - 1):
		if r[j] > r[j - 1] and r[j] > r[j + 1]:
			f = 1
			break
	if f == 1:
		print('YES')
		print(j, j + 1, j + 2)
	else:
		print('NO')


t = int(input())
for i in range(t):
	n = int(input())
	a = [int(x) for x in input().split()]
	check = 0
	for i in range(1, n - 1):
		if a[i] > a[i - 1] and a[i] > a[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			check = 1
			break
	if check == 0:
		print('NO')


for i in range(int(input())):
	n = int(input())
	ar = list(map(int, input().split()))
	solved = False
	for j in range(1, n - 1):
		if ar[j - 1] < ar[j] and ar[j] > ar[j + 1]:
			solved = True
			idx = j
			break
	if solved:
		print('YES')
		print(idx, idx + 1, idx + 2)
	else:
		print('NO')


tests = int(input())

def solve(arr):
	leftPref = [[arr[0], 0]]
	for i in range(1, len(arr)):
		if leftPref[-1][0] > arr[i]:
			leftPref.append([arr[i], i])
		else:
			leftPref.append(leftPref[-1])
	rightPref = [[arr[-1], len(arr) - 1] for _ in range(len(arr))]
	for i in range(len(arr) - 2, -1, -1):
		if arr[i] < rightPref[i + 1][0]:
			rightPref[i] = [arr[i], i]
		else:
			rightPref[i] = rightPref[i + 1]
	for i in range(1, len(arr) - 1):
		left = leftPref[i - 1]
		right = rightPref[i + 1]
		if left[0] < arr[i] and right[0] < arr[i]:
			return (left[1] + 1, i + 1, right[1] + 1)
	return -1
while tests > 0:
	n = int(input())
	arr = list(map(int, input().split()))
	ans = solve(arr)
	if ans != -1:
		print('YES')
		print(ans[0], ans[1], ans[2])
	else:
		print('NO')
	tests -= 1


for tt in range(int(input())):
	n = int(input())
	a = list(map(int, input().split()))
	for i in range(1, n - 1):
		if a[i - 1] < a[i] > a[i + 1]:
			print('YES')
			print(i - 1 + 1, i + 1, i + 1 + 1)
			break
	else:
		print('NO')


testCases = int(input())
while testCases > 0:
	size = int(input())
	elements = list(map(int, input().split()))
	i = 0
	j = -1
	smallestLeft = False
	biggestMiddle = False
	for m in range(size):
		if smallestLeft == False:
			if elements[m] < elements[i]:
				i = m
			if elements[m] > elements[i]:
				j = m
				smallestLeft = True
			continue
		if biggestMiddle == False:
			if elements[m] > elements[j]:
				j = m
			if elements[m] < elements[j]:
				print('YES')
				print(i + 1, j + 1, m + 1)
				biggestMiddle = True
				break
			continue
	if biggestMiddle == False:
		print('NO')
	testCases -= 1


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	left = [-1]
	s = [0]
	for i in range(1, n):
		while len(s) > 0 and l[i] < l[s[-1]]:
			s.pop()
		if len(s) > 0:
			left.append(s[-1])
		else:
			left.append(-1)
		s.append(i)
	right = [-1] * n
	s = [n - 1]
	for i in range(n - 2, -1, -1):
		while len(s) > 0 and l[i] < l[s[-1]]:
			s.pop()
		if len(s) > 0:
			right[i] = s[-1]
		s.append(i)
	flag = 1
	for i in range(n):
		if left[i] != -1 and right[i] != -1:
			print('YES')
			print(left[i] + 1, i + 1, right[i] + 1)
			flag = 0
			break
	if flag == 1:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	p = list(map(int, input().split()))
	a = list(p)
	a.sort()
	a.reverse()
	for i in range(n):
		z = p.index(a[i])
		if z != 0 and z != n - 1:
			if p[z] > p[z - 1] and p[z] > p[z + 1]:
				print('YES')
				print(z, z + 1, z + 2)
				break
	else:
		print('NO')


t = int(input())
for _ in range(t):
	n = int(input())
	A = [int(x) for x in input().split()]
	for i in range(1, n - 1):
		if A[i - 1] < A[i] and A[i] > A[i + 1]:
			print('YES')
			print(i, i + 1, i + 2)
			break
	else:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	arr = list((int(i) for i in input().split()))
	ans = []
	for i in range(1, n - 1):
		if arr[i] > arr[i - 1] and arr[i] > arr[i + 1]:
			ans.append(i)
			ans.append(i + 1)
			ans.append(i + 2)
			break
	if len(ans) == 0:
		print('NO')
	else:
		print('YES')
		print(*ans)


production = True
import sys, math, collections

def input(input_format=0, multi=0):
	if multi > 0:
		return [input(input_format) for i in range(multi)]
	else:
		next_line = sys.stdin.readline()[:-1]
		if input_format >= 10:
			use_list = False
			input_format = int(str(input_format)[-1])
		else:
			use_list = True
		if input_format == 0:
			formatted_input = [next_line]
		elif input_format == 1:
			formatted_input = list(map(int, next_line.split()))
		elif input_format == 2:
			formatted_input = list(map(float, next_line.split()))
		elif input_format == 3:
			formatted_input = list(next_line)
		elif input_format == 4:
			formatted_input = list(map(int, list(next_line)))
		elif input_format == 5:
			formatted_input = next_line.split()
		else:
			formatted_input = [next_line]
		return formatted_input if use_list else formatted_input[0]

def out(output_line, output_format=0, newline=True):
	formatted_output = ''
	if output_format == 0:
		formatted_output = str(output_line)
	elif output_format == 1:
		formatted_output = ' '.join(map(str, output_line))
	elif output_format == 2:
		formatted_output = '\n'.join(map(str, output_line))
	print(formatted_output, end='\n' if newline else '')

def log(*args):
	if not production:
		print('$$$', end='')
		print(*args)
enu = enumerate
ter = lambda a, b, c: b if a else c
ceil = lambda a, b: -(-a // b)

def mapl(iterable, format=0):
	if format == 0:
		return list(map(int, iterable))
	elif format == 1:
		return list(map(str, iterable))
	elif format == 2:
		return list(map(list, iterable))

def solve():
	n = input(11)
	p = input(1)
	for i in range(n - 2):
		if p[i] < p[i + 1] and p[i + 1] > p[i + 2]:
			out('YES')
			out(list(range(i + 1, i + 4)), 1)
			break
	else:
		out('NO')
	return
for i in range(input(11)):
	solve()


t = int(input())
for i in range(t):
	l = int(input())
	x = list(map(int, input().split()))
	ok = False
	for j in range(l):
		m1 = int(1000000000.0)
		i1 = 0
		m2 = int(1000000000.0)
		i2 = 0
		for k in range(j):
			if x[k] < m1:
				m1 = x[k]
				i1 = k
		for k in range(j + 1, l):
			if x[k] < m2:
				m2 = x[k]
				i2 = k
		if m1 < x[j] and x[j] > m2:
			print('YES')
			print(i1 + 1, j + 1, i2 + 1)
			ok = True
			break
	if not ok:
		print('NO')


for _ in range(int(input())):
	n = int(input())
	l = list(map(int, input().split()))
	flag = False
	arr = []
	for i in range(2, n):
		if l[i - 2] < l[i - 1] and l[i - 1] > l[i]:
			flag = True
			print('YES')
			arr.extend([i - 1, i, i + 1])
			print(*arr)
			break
	if not flag:
		print('NO')


def solve():
	t = int(input())
	for _ in range(t):
		n = int(input())
		s = list(map(int, input().split()))
		ans = []
		for i in range(0, n - 2):
			(j, k) = (i + 1, i + 2)
			if s[i] > s[j]:
				j += 1
				k += 1
			elif s[i] < s[j] < s[k]:
				k += 1
			elif s[i] < s[j] and s[j] > s[k]:
				ans.append([i + 1, j + 1, k + 1])
				break
		if not ans:
			print('NO')
		else:
			print('YES')
			print(*ans[0])
solve()


t = int(input())
while t:
	n = int(input())
	arr = list(map(int, input().split()))
	ans = [0] * 3
	for i in range(n - 2):
		if arr[i] < arr[i + 1] and arr[i + 1] > arr[i + 2]:
			(ans[0], ans[1], ans[2]) = (i + 1, i + 2, i + 3)
	if all(ans):
		print('YES')
		print(*ans)
	else:
		print('NO')
	t -= 1


t = int(input())
for _ in range(t):
	n = int(input())
	lst = list(map(int, input().split()))
	i = 0
	found = False
	for index in range(1, n - 1):
		if lst[index] > lst[index - 1] and lst[index + 1] < lst[index]:
			found = True
			break
	if found:
		print('YES')
		print(index, index + 1, index + 2)
	else:
		print('NO')


for i in range(int(input())):
	n = int(input())
	l = list(map(int, input().rstrip().split(' ')))
	r = []
	for i in range(1, n - 1):
		if l[i - 1] < l[i] and l[i] > l[i + 1]:
			r = [i, i + 1, i + 2]
			break
	if r:
		print('YES')
		print(*r)
	else:
		print('NO')


import math
from collections import deque
import sys
sys.setrecursionlimit(10 ** 4)

def Divisors(n):
	l = []
	i = 2
	while i <= math.sqrt(n):
		if n % i == 0:
			if n // i == i:
				l.append(i)
			else:
				l.append(i)
				l.append(n // i)
		i = i + 1
	return l

def SieveOfEratosthenes(n):
	l = []
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	for p in range(2, n + 1):
		if prime[p]:
			l.append(p)
	return l

def primeFactors(n):
	l = []
	while n % 2 == 0:
		l.append(2)
		n = n / 2
	for i in range(3, int(math.sqrt(n)) + 1, 2):
		while n % i == 0:
			l.append(i)
			n = n / i
	if n > 2:
		l.append(n)
	return l

def Factors(n):
	result = []
	for i in range(2, int(math.sqrt(n)) + 1):
		if n % i == 0:
			if i == n / i:
				result.append(i)
			else:
				result.append(i)
				result.append(n // i)
	result.append(1)
	return result

def maxSubArraySum(a):
	max_so_far = 0
	max_ending_here = 0
	size = len(a)
	for i in range(0, size):
		max_ending_here = max_ending_here + a[i]
		if max_so_far < abs(max_ending_here):
			max_so_far = max_ending_here
	return max_so_far

def longestsubarray(arr, n, k):
	current_count = 0
	max_count = 0
	for i in range(0, n, 1):
		if arr[i] % k != 0:
			current_count += 1
		else:
			current_count = 0
		max_count = max(current_count, max_count)
	return max_count

def main():
	n = int(input())
	l = list(map(int, input().split()))
	f = 0
	for j in range(1, n - 1):
		if min(l[0:j]) < l[j] and min(l[j + 1:n]) < l[j]:
			f = 1
			break
	if f == 1:
		print('YES')
		m = n
		ans1 = 0
		for k in range(0, j):
			if l[k] < m:
				m = l[k]
				ans1 = k
		m = n
		ans2 = 0
		for k in range(j + 1, n):
			if l[k] < m:
				m = l[k]
				ans2 = k
		print(ans1 + 1, j + 1, ans2 + 1)
	else:
		print('NO')
t = int(input())
for i in range(0, t):
	main()


import bisect
import copy
import fractions
import heapq
import math
import random
import sys
T = int(input())
for t in range(T):
	N = int(input())
	nums = list(map(int, input().split()))
	(I, J, K) = (None, None, None)
	for i in range(N):
		if I is None:
			I = i
		elif J is None:
			if nums[i] < nums[I]:
				I = i
			elif nums[i] > nums[I]:
				J = i
		elif nums[i] > nums[J]:
			J = i
		elif nums[i] < nums[J]:
			K = i
			break
	if K is None:
		print('NO')
	else:
		print('YES')
		print(str(I + 1) + ' ' + str(J + 1) + ' ' + str(K + 1))


for _ in range(int(input())):

	def main():
		n = int(input())
		s = list(map(int, input().split()))
		for i in range(1, n - 1):
			if s[i] > s[i - 1] and s[i] > s[i + 1]:
				print('YES')
				print(i, i + 1, i + 2)
				return None
		print('NO')
	main()


t = int(input())
for i in range(t):
	n = int(input())
	p = [int(s) for s in input().split()]
	ans = [1e+16]
	ans2 = [1e+16]
	for k in range(n):
		if p[k] < ans[-1] and len(ans) < 2:
			ans[-1] = p[k]
			ans2[-1] = k + 1
		elif p[k] > ans[-1] and len(ans) < 2:
			ans.append(p[k])
			ans2.append(k + 1)
		elif p[k] > ans[-1] and len(ans) > 1:
			ans[-1] = p[k]
			ans2[-1] = k + 1
		elif p[k] < ans[-1] and len(ans) > 1:
			ans.append(p[k])
			ans2.append(k + 1)
			break
	if len(ans) == 3:
		print('YES')
		print(*ans2)
	else:
		print('NO')


T = int(input())

def solve():
	N = int(input())
	P = list(map(int, input().split()))
	min_right_idx = [None] * N
	min_left_idx = [None] * N
	for i in range(N - 1, -1, -1):
		if i == N - 1:
			min_right_idx[i] = i
		elif P[i] < P[min_right_idx[i + 1]]:
			min_right_idx[i] = i
		else:
			min_right_idx[i] = min_right_idx[i + 1]
	for i in range(N):
		if i == 0:
			min_left_idx[i] = i
		elif P[i] < P[min_left_idx[i - 1]]:
			min_left_idx[i] = i
		else:
			min_left_idx[i] = min_left_idx[i - 1]
	for i in range(1, N - 1):
		if P[min_left_idx[i]] < P[i] and P[i] > P[min_right_idx[i]]:
			print('YES')
			print('{} {} {}'.format(1 + min_left_idx[i], 1 + i, 1 + min_right_idx[i]))
			return
	print('NO')
for _ in range(T):
	solve()