#include <bits/stdc++.h>
using namespace std;
const int N = 4e5 + 10;
int a[N];
int vis[N];
int sum[4 * N];
void up(int id, int l, int r, int pos, int val) {
  if (l == r) {
    sum[id] = val;
    return;
  }
  int mid = l + r >> 1;
  if (pos <= mid)
    up(id << 1, l, mid, pos, val);
  else
    up(id << 1 | 1, mid + 1, r, pos, val);
  sum[id] = max(sum[id << 1], sum[id << 1 | 1]);
}
int qu(int id, int l, int r, int ql, int qr) {
  if (ql <= l && r <= qr) return sum[id];
  int mx = 0;
  int mid = l + r >> 1;
  if (ql <= mid) mx = max(mx, qu(id << 1, l, mid, ql, qr));
  if (qr > mid) mx = max(mx, qu(id << 1 | 1, mid + 1, r, ql, qr));
  return mx;
}
int main() {
  int n;
  cin >> n;
  for (int i = 1; i <= (n); ++i) cin >> a[i];
  int q;
  cin >> q;
  int h;
  int le = 0;
  int pre = 0;
  for (int i = 1; i <= q; ++i) {
    int ty;
    cin >> ty;
    if (ty == 1) {
      int pos, val;
      cin >> pos >> val;
      vis[pos] = i;
      a[pos] = val;
    } else {
      cin >> h;
      up(1, 1, q, i, h);
    }
  }
  for (int i = 1; i <= (n); ++i) {
    int le = qu(1, 1, q, vis[i], q);
    if (le > a[i])
      printf("%d ", le);
    else
      printf("%d ", a[i]);
  }
}
