#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, q;
  cin >> n;
  vector<long> a(n);
  for (i = 0; i < n; i++) {
    cin >> a[i];
  }
  cin >> q;
  vector<int> t(q);
  vector<int> p(q);
  vector<long> x(q);
  for (i = 0; i < q; i++) {
    cin >> t[i];
    if (t[i] == 1) {
      cin >> p[i] >> x[i];
    } else {
      cin >> x[i];
    }
  }
  vector<long> give(q);
  long M = -1;
  for (i = q - 1; i >= 0; i--) {
    if (t[i] == 2) {
      if (x[i] > M) {
        M = x[i];
      }
    }
    give[i] = M;
  }
  vector<int> hit(n);
  for (i = 0; i < q; i++) {
    if (t[i] == 1) {
      a[p[i] - 1] = x[i];
      if (give[i] > a[p[i] - 1]) {
        a[p[i] - 1] = give[i];
      }
      hit[p[i] - 1]++;
    }
  }
  for (i = 0; i < n; i++) {
    if (hit[i]) {
      cout << a[i];
    } else {
      if (M > a[i]) {
        cout << M;
      } else {
        cout << a[i];
      }
    }
    cout << " ";
  }
}
