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.util.*;
import java.util.Scanner;
import java.io.*;
import javax.lang.model.util.ElementScanner6; 
import static java.lang.System.out;


public class C1433
{

   
    
    public static void main(String args[])
    {  

        FastReader in=new FastReader();
        PrintWriter pr = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
        int tc=1;
     
        tc=in.nextInt();
        while(tc-->0)
        {
            
        	int n=in.nextInt();
        	long arr[]=new long[n];
        	
        	long max=0;
        	for(int i=0;i<n;i++)
        	{
				
				arr[i]=in.nextLong();
				max=Math.max(arr[i],max);
			}
			
			
			int pos=-1;
			int flag=0;
			for(int i=0;i<n;i++)
			{
				
				if(arr[i]==max)
				{
					if(i>0&&i<n-1)
					{
						if(arr[i]>arr[i-1]||arr[i]>arr[i+1])
						{
							pos=i+1;
							flag=1;
							break;
						}
					}
					else if(i>0)
					{
						if(arr[i]>arr[i-1])
						{
							pos=i+1;
							flag=1;
							break;
						}
						
					}
					else
					{
						if(arr[i]>arr[i+1])
						{
							pos=i+1;
							flag=1;
							break;
						}
					}
					
				}
				
			}
				
			
			
			
			if(flag==0)
			{
				
			pr.println(-1);
			}
			
			
			else pr.println(pos);
			
        	
        	
        	
        	
        	

        



        }
        pr.flush();
    }



    

    static void sort(long[] a) {
		ArrayList<Long> l = new ArrayList<>();
		for (long i : a)
			l.add(i);
		Collections.sort(l);
		for (int i = 0; i < a.length; i++)
			a[i] = l.get(i);
	}
    
    
	static void sort(int[] a) {
		ArrayList<Integer> l = new ArrayList<>();
		for (int i : a)
			l.add(i);
		Collections.sort(l);
		for (int i = 0; i < a.length; i++)
			a[i] = l.get(i);
    }

    
    static class FastReader
    { 
        BufferedReader br; 
        StringTokenizer st; 

        public FastReader() 
        { 
            br = new BufferedReader(new InputStreamReader(System.in)); 
        } 

        String next() 
        { 
            while (st == null || !st.hasMoreElements()) 
            { 
                try
                { 
                    st = new StringTokenizer(br.readLine()); 
                } 
                catch (IOException  e) 
                { 
                    e.printStackTrace(); 
                } 
            } 
            return st.nextToken(); 
        } 

        int nextInt() 
        { 
            return Integer.parseInt(next()); 
        } 

        long nextLong() 
        { 
            return Long.parseLong(next()); 
        } 

        double nextDouble() 
        { 
            return Double.parseDouble(next()); 
        } 

        String nextLine() 
        { 
            String str = ""; 
            try
            { 
                str = br.readLine(); 
            } 
            catch (IOException e) 
            { 
                e.printStackTrace(); 
            } 
            return str; 
        } 
    } 
}
