1
3
5 3 4
 6
5
5 3 4 4 5
3
1 1 1
5
4 4 3 4 4
5
5 5 4 3 2
3
1 1 2
5
5 4 3 5 5
 1
3
10 1 5

1
 1
-1
2
2
3
1
 1

# from collections import defaultdict

import io, os, math
input = io.BytesIO(os.read(0,os.fstat(0).st_size)).readline

rr = lambda: input()
rri = lambda: int(input())
rrm = lambda: list(map(int, input().split()))

INF=float('inf')

def solve(N,A):
	need = float('inf') # for dominant piranha
	for v in A:
		# to eat current v+1 or keep from current need
		need = min(v+1, need)
		#print(need)

	#print("final need ", need)
	for i in range(N):
		if need <= A[i]:
			return i+1
	return -1

t = rri()
for _ in range(t):
	N = rri()
	A = rrm()
	print(solve(N,A))
