You are given 4n sticks, the length of the i-th stick is a_i.

You have to create n rectangles, each rectangle will consist of exactly 4 sticks from the given set. The rectangle consists of four sides, opposite sides should have equal length and all angles in it should be right. Note that each stick can be used in only one rectangle. Each stick should be used as a side, you cannot break the stick or use it not to the full length.

You want to all rectangles to have equal area. The area of the rectangle with sides a and b is a ⋅ b.

Your task is to say if it is possible to create exactly n rectangles of equal area or not.

You have to answer q independent queries.

Input

The first line of the input contains one integer q (1 ≤ q ≤ 500) — the number of queries. Then q queries follow.

The first line of the query contains one integer n (1 ≤ n ≤ 100) — the number of rectangles.

The second line of the query contains 4n integers a_1, a_2, ..., a_{4n} (1 ≤ a_i ≤ 10^4), where a_i is the length of the i-th stick.

Output

For each query print the answer to it. If it is impossible to create exactly n rectangles of equal area using given sticks, print "NO". Otherwise print "YES".

Example

Input


5
1
1 1 10 10
2
10 5 2 10 1 1 2 5
2
10 5 1 10 5 1 1 1
2
1 1 1 1 1 1 1 1
1
10000 10000 10000 10000


Output


YES
YES
NO
YES
YES
import java.io.*;
import java.math.BigInteger;
import java.util.*;
import static java.lang.Math.*;
public class Reader_ {
    public static void main(String[] args) {
        new Thread(null, null, "Rahsut", 1 << 25) {
            public void run() {
                try {
                    F___k();
                } catch (Exception e) {
                    e.printStackTrace();
                    System.exit(1);
                }
            }
        }.start();
    }
    static class Reader {
        final private int BUFFER_SIZE = 1 << 16;
        private DataInputStream din;
        private byte[] buffer;
        private int bufferPointer, bytesRead;

        public Reader() {
            din = new DataInputStream(System.in);
            buffer = new byte[BUFFER_SIZE];
            bufferPointer = bytesRead = 0;
        }

        public Reader(String file_name) throws IOException {
            din = new DataInputStream(new FileInputStream(file_name));
            buffer = new byte[BUFFER_SIZE];
            bufferPointer = bytesRead = 0;
        }

        public String readLine() throws IOException {
            byte[] buf = new byte[64]; // line length
            int cnt = 0, c;
            while ((c = read()) != -1) {
                if (c == '\n')
                    break;
                buf[cnt++] = (byte) c;
            }
            return new String(buf, 0, cnt);
        }

        public int nextInt() throws IOException {
            int ret = 0;
            byte c = read();
            while (c <= ' ')
                c = read();
            boolean neg = (c == '-');
            if (neg)
                c = read();
            do {
                ret = ret * 10 + c - '0';
            } while ((c = read()) >= '0' && c <= '9');

            if (neg)
                return -ret;
            return ret;
        }

        public long nextLong() throws IOException {
            long ret = 0;
            byte c = read();
            while (c <= ' ')
                c = read();
            boolean neg = (c == '-');
            if (neg)
                c = read();
            do {
                ret = ret * 10 + c - '0';
            }
            while ((c = read()) >= '0' && c <= '9');
            if (neg)
                return -ret;
            return ret;
        }

        public double nextDouble() throws IOException {
            double ret = 0, div = 1;
            byte c = read();
            while (c <= ' ')
                c = read();
            boolean neg = (c == '-');
            if (neg)
                c = read();

            do {
                ret = ret * 10 + c - '0';
            }
            while ((c = read()) >= '0' && c <= '9');

            if (c == '.') {
                while ((c = read()) >= '0' && c <= '9') {
                    ret += (c - '0') / (div *= 10);
                }
            }

            if (neg)
                return -ret;
            return ret;
        }

        private void fillBuffer() throws IOException {
            bytesRead = din.read(buffer, bufferPointer = 0, BUFFER_SIZE);
            if (bytesRead == -1)
                buffer[0] = -1;
        }

        private byte read() throws IOException {
            if (bufferPointer == bytesRead)
                fillBuffer();
            return buffer[bufferPointer++];
        }

        public void close() throws IOException {
            if (din == null)
                return;
            din.close();
        }
    }
    static class Pair implements Comparable<Pair> {
        int x, y;

        public Pair(int x, int y) {
            this.x = x;
            this.y = y;
        }

        public int compareTo(Pair o) {
            if (x != o.x)
                return x - o.x;
            return this.y - o.y;
        }

        public int hashCode() {
            return (int) (1L * 1000000000 * x + y) % 1000000007;
        }

        public boolean equals(Object o) {
            if (o instanceof Pair) {
                Pair other = (Pair) o;
                return other.hashCode() == this.hashCode();
            } else return false;
        }

        public String toString() {
            return x + " " + y;
        }
    }
    static long mul(long a, long b) {
        a %= mod;
        b %= mod;
        return (a * b) % mod;
    }
    static long modPow(long x, long p) {
        if (p == 0)
            return 1;
        if (p % 2 == 0)
            return modPow((x * x) % mod, p >> 1) % mod;
        return (x * modPow(x, p - 1) % mod) % mod;
    }
    static long gcd(long a, long b) {
        if (b % a == 0)
            return a;
        return gcd(b % a, a);
    }
    static StringBuilder sb = new StringBuilder();
    static PrintWriter pw = new PrintWriter(System.out, true);

    //global variables
    //static Scanner sc = new Scanner(System.in);
    static Reader sc = new Reader();
    static ArrayList<Integer> adj[];
    static long dp[][][], mod = (long) 1e9 + 7, arr[];
    static int dir1[][] = {{1, 0}, {-1, 0}, {0, 1}, {0, -1}}, dir2[][] = {{-1, -1}, {-1, 1}, {1, -1}, {1, 1}};

    static void F___k() throws IOException {
        //write Code here
        int t = sc.nextInt();
        while(t-->0) {
            int n = sc.nextInt();
            int arr[] = new int[4 * n];
            int len[] = new int[10001];
            for (int i = 0; i < 4 * n; i++) {
                arr[i] = sc.nextInt();
                len[arr[i]]++;
            }
            boolean bool = false;
            for (int i : len) {
                if (i % 2 != 0) {
                    sb.append("NO\n");
                    bool = true;
                    break;
                }
            }
            if (bool)
                continue;
            Arrays.sort(arr);
            int i = 0, j = 4 * n - 1;
            long area = arr[i] * arr[j];
            while (i + 2 < j) {
                i += 2;
                j -= 2;
                // System.out.println(area+"  "+(arr[i]*arr[j]));
                if (area != arr[i] * arr[j]) {
                    sb.append("NO\n");
                    area = 0;
                    break;
                }
            }
            if (area > 0) {
                sb.append("YES\n");
            }
        }
        pw.println(sb);
        pw.flush();
        pw.close();
    }
}