func_code_string: #include <bits/stdc++.h>   using namespace std;   int main() {     ios_base::sync_with_stdio(false);     cin.tie(0);     int t;     cin >> t;     while (t--) {       int n;       cin >> n;       vector<int> a(n);       map<int, int> cur;       set<pair<int, int>> st;       for (int i = 0; i < n; i++) {         cin >> a[i];         if (!cur.count(a[i])) {           st.insert(make_pair(a[i], i));         }         cur[a[i]] = i;       }       if (st.size() == 1) {         cout <<  NO  << endl;         continue;       } else {         cout <<  YES  << endl;         vector<pair<int, int>> res;         auto e = st.begin(), g = prev(st.end());         for (int i = 0; i < n; i++) {           if (a[i] != e->first) {             res.emplace_back(i + 1, e->second + 1);           } else if (i != g->second && i != e->second)             res.emplace_back(i + 1, g->second + 1);         }         for (auto j : res) cout << j.first <<     << j.second << endl;       }     }     return 0;   }   