#include <bits/stdc++.h>
using namespace std;
const int maxn = 3e5 + 10;
const int modd = 1e9 + 7;
const int inf = 0x3f3f3f3f;
long long n, q, p, x, d;
long long a[maxn], b[maxn], c[maxn];
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cin >> n;
  for (int i = 1; i <= n; ++i) {
    cin >> a[i];
  }
  cin >> q;
  for (int i = 1; i <= q; ++i) {
    cin >> d;
    if (d == 1) {
      cin >> p >> x;
      a[p] = x;
      b[p] = i;
    } else if (d == 2) {
      cin >> x;
      c[i] = x;
    }
  }
  for (int i = q; i >= 1; --i) {
    c[i - 1] = max(c[i - 1], c[i]);
  }
  cout << max(a[1], c[b[1]]);
  for (int i = 2; i <= n; i++) {
    cout << " " << max(a[i], c[b[i]]);
  }
  return 0;
}
