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

n = int(input())

def test(items):
    aim = max(items)
    for idx, item in enumerate(items):
        if item == aim:
            if idx == 0:
                if len(items) > 1 and item > items[idx+1]:
                    return idx+1
            else:
                if idx == len(items) - 1:
                    if item > items[idx-1]:
                        return idx+1
                else:
                    if item > items[idx-1] or item > items[idx+1]:
                        return idx+1
    return -1


for _ in range(n):
    _ = input()
    items = tuple(map(int, input().split()))
    print(test(items))