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

/**
 * @author tania_mnnit
 * created on 2020-10-20 19:56
 */
import java.io.*;
import java.util.*;
public class Main
{
	private void solve()throws Exception
	{
		int n=nextInt();
		int a[]=new int[n+1];
		int max=0;
		for(int i=1;i<=n;i++)
		{
			a[i]=nextInt();
			max=Math.max(max,a[i]);
		}
		for(int i=1;i<=n;i++)
			if(a[i]==max && (i-1>=1 && a[i-1]<max || i+1<=n && a[i+1]<max))
			{
				out.println(i);
				return;
			}
		out.println(-1);
	}

	 
	///////////////////////////////////////////////////////////

	public void run()throws Exception
	{
		br=new BufferedReader(new InputStreamReader(System.in));
		st=null;
		out=new PrintWriter(System.out);

		try{
			int t=nextInt();
			while(t-->0)
			solve();

		}catch(Exception e){e.printStackTrace();}
		finally{
			br.close();
			out.close();
		}
		
	}
	public static void main(String args[])throws Exception{
		new Main().run();
	}
	BufferedReader br;
	StringTokenizer st;
	PrintWriter out;
	String nextToken()throws Exception{
		while(st==null || !st.hasMoreTokens())
		st=new StringTokenizer(br.readLine());
		return st.nextToken();
	}
	String nextLine()throws Exception{
		return br.readLine();
	}
	int nextInt()throws Exception{
		return Integer.parseInt(nextToken());
	}
	long nextLong()throws Exception{
		return Long.parseLong(nextToken());
	}
	double nextDouble()throws Exception{
		return Double.parseDouble(nextToken());
	}
}
