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 sys import maxsize, stdout, stdin
mod = int(1e9 + 7)
def I(): return int(stdin.readline())
def lint(): return [int(x) for x in stdin.readline().split()]
def S(): return input().strip()
def grid(r, c): return [lint() for i in range(r)]
for _ in range(I()):
    n = I()
    ls =lint()
    if len(set(ls))==1:
        print(-1)
    else:
        m = -1
        idx =0
        for i in range(n):
            if i <n-1:
                if ls[i] > ls[i+1]:
                    if ls[i] > m:
                        m = ls[i]
                        idx = i
            if i >0:
                if ls[i] > ls[i-1]:
                    if ls[i] > m:
                        m = ls[i]
                        idx = i
        print(idx+1)
