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

import java.io.*;
import java.sql.SQLOutput;
import java.text.*;
import java.util.Scanner;;
public  class Main{

    public  static  void main(String[] args){

        Scanner scan=new Scanner(System.in);
        int t=scan.nextInt();
        while(t!=0){t--;
            int n=scan.nextInt(),cnt=0,hold=1;
                int []a=new int[n+1];
                int maxi=0; boolean x=false;
                a[1]=scan.nextInt();
                maxi=a[1];
                for(int i=2;i<=n;i++)
                { a[i]=scan.nextInt();
                if(a[i]!=a[i-1])
                    x=true;
                if(a[i]>maxi)
                { maxi=a[i];
                hold=i;
                }}
                if(x)
                System.out.println(hold);
                else
                    System.out.println("-1");
        }}}