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.util.StringTokenizer;

public class C implements Runnable {
    public static void main(String [] args) {
        new Thread(null, new C(), "whatever", 1<<26).start();
    }

    public void run() {

        FastScanner s = new FastScanner(System.in);
        StringBuilder sb = new StringBuilder();

        int t = s.nextInt();
        for (int ii = 0; ii < t; ii++) {
            int n  = s.nextInt();
            int[] nums = new int[n];

            for (int i = 0; i < n; i++) {
                nums[i] = s.nextInt();
            }

                int max = Integer.MIN_VALUE;



            for (int j = 0; j < n; j++) {
                int next = nums[j];
                if (next > max) {
                    max = next;

                }
            }

            int found = -1;
            for (int i = 0; i < n; i++) {
                if (nums[i] == max) {
                    if ((i > 0 && nums[i - 1] < nums[i]) ||
                    (i < n - 1 && nums[i + 1] < nums[i])
                ) {
                        found = i + 1;
                    }
                }
            }

            sb.append(found);
            sb.append("\n");
        }
        System.out.print(sb);
    }

    class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner(Reader in) {
            br = new BufferedReader(in);
        }

        public FastScanner(InputStream in) {
            this(new InputStreamReader(in));
        }

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

        public int nextInt() {
            return Integer.parseInt(next());
        }
        public long nextLong() {
            return Long.parseLong(next());
        }
        public double nextDouble() { return Double.parseDouble(next());}

    }
}