#include <bits/stdc++.h>
using namespace std;
int tt, n, i, j, k, l, m, ma[505], mi, h[505], t[505], no, p, aa, bb, dp[305];
int a[201010], b[201010], v[201010], d[2010][2020], sx;
string ans, s;
int main() {
  cin >> n;
  for (i = 1; i <= n; i++) {
    cin >> a[i];
  }
  cin >> m;
  for (i = 1; i <= m; i++) {
    cin >> k;
    if (k == 1) {
      cin >> l >> j;
      a[l] = j;
      b[l] = i;
    } else {
      cin >> v[i];
    }
  }
  for (i = m - 1; i >= 1; i--) {
    v[i] = max(v[i + 1], v[i]);
  }
  for (i = 1; i <= n; i++) {
    cout << max(a[i], v[b[i] + 1]) << " ";
  }
}
