func_code_string: #include <bits/stdc++.h>   using namespace std;   int main() {     ios::sync_with_stdio(0);     cin.tie(0);     cout.tie(0);     int t;     cin >> t;     for (int i = 0; i < t; i++) {       int n;       cin >> n;       vector<int> p(n), result;       for (int& j : p) {         cin >> j;       }       vector<int> maximums;       vector<bool> used(n, false);       result.push_back(p[0]);       used[p[0] - 1] = true;       int idx = 0;       for (idx; idx < p[0] - 1; idx++) {         maximums.push_back(idx + 1);       }       idx++;       for (int j = 1; j < n; j++) {         if (p[j] > p[j - 1]) {           result.push_back(p[j]);           used[p[j] - 1] = true;           for (idx; idx < p[j] - 1; idx++) {             if (!used[idx]) maximums.push_back(idx + 1);           }           idx++;         } else {           if (maximums.size() > 0) {             used[maximums[maximums.size() - 1] - 1] = true;             result.push_back(maximums[maximums.size() - 1]);             maximums.pop_back();           }         }       }       if (result.size() < n)         cout << -1 << endl;       else {         for (int& i : result) {           cout << i <<    ;         }         cout << endl;       }     }   }   