#include <bits/stdc++.h>
using namespace std;
int a[200001];
int n, q;
int qtype, x, val;
int Qs[200001][3];
int changed[200001];
int univ = 0;
int main() {
  if (0) freopen("in", "r", stdin);
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> a[i];
  cin >> q;
  for (int i = 0; i < q; i++) {
    cin >> qtype;
    Qs[i][0] = qtype;
    switch (qtype) {
      case 1:
        cin >> x >> val;
        Qs[i][1] = x;
        Qs[i][2] = val;
        break;
      case 2:
        cin >> val;
        Qs[i][1] = val;
        break;
      default:
        assert(0);
    }
  }
  val = -1;
  while (--q > -1) {
    if (0)
      cout << "Query #" << q << " " << Qs[q][0] << ' ' << Qs[q][1] << " "
           << Qs[q][2] << endl;
    switch (Qs[q][0]) {
      case 1:
        x = Qs[q][1];
        val = Qs[q][2];
        if (!changed[x]) {
          a[x] = max(val, univ);
          changed[x] = 1;
        }
        break;
      case 2:
        val = Qs[q][1];
        univ = max(univ, val);
        break;
    }
  }
  for (int i = 1; i <= n; i++) {
    if (changed[i]) {
      cout << a[i] << ' ';
    } else {
      cout << max(a[i], univ) << ' ';
    }
  }
}
