#include <bits/stdc++.h>
using namespace std;
const int MAXN = 2 * 100 * 1000 + 17;
int n, a[MAXN], q, mx[MAXN];
pair<int, pair<int, int> > qu[MAXN];
bool mark[MAXN];
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> a[i];
  cin >> q;
  for (int i = 1; i <= q; i++) {
    int t, p, x = 0;
    cin >> t >> p;
    if (t == 1) cin >> x;
    qu[i] = {t, {p, x}};
  }
  for (int i = q; i >= 0; i--) {
    if (qu[i].first == 2)
      mx[i] = max(mx[i + 1], qu[i].second.first);
    else
      mx[i] = mx[i + 1];
  }
  for (int i = q; i > 0; i--) {
    if (qu[i].first == 1)
      if (mark[qu[i].second.first] == false) {
        mark[qu[i].second.first] = true;
        a[qu[i].second.first] = max(mx[i], qu[i].second.second);
      }
  }
  for (int i = 1; i <= n; i++)
    if (!mark[i]) a[i] = max(a[i], mx[0]);
  for (int i = 1; i <= n; i++) cout << a[i] << " ";
  return 0;
}
