#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 10;
int d[4][2] = {1, 0, -1, 0, 0, 1, 0, -1};
int minn[maxn << 2], maxx[maxn << 2], lazy[maxn << 2], a[maxn];
void pushdown(int rt) {
  if (lazy[rt] != -1) {
    lazy[rt << 1] = lazy[(rt << 1) + 1] = maxx[rt << 1] = minn[rt << 1] =
        maxx[(rt << 1) + 1] = minn[(rt << 1) + 1] = lazy[rt];
    lazy[rt] = -1;
  }
}
void build(int rt, int L, int R) {
  lazy[rt] = -1;
  if (L == R) {
    minn[rt] = maxx[rt] = a[L];
    return;
  }
  int mid = (L + R) >> 1;
  build(rt << 1, L, mid);
  build((rt << 1) + 1, mid + 1, R);
  minn[rt] = min(minn[rt << 1], minn[(rt << 1) + 1]);
  maxx[rt] = max(maxx[rt << 1], maxx[(rt << 1) + 1]);
}
void update1(int rt, int L, int R, int pos, int val) {
  if (L == R) {
    maxx[rt] = minn[rt] = val;
    return;
  }
  pushdown(rt);
  int mid = (L + R) >> 1;
  if (pos <= mid)
    update1(rt << 1, L, mid, pos, val);
  else
    update1((rt << 1) + 1, mid + 1, R, pos, val);
  minn[rt] = min(minn[rt << 1], minn[(rt << 1) + 1]);
  maxx[rt] = max(maxx[rt << 1], maxx[(rt << 1) + 1]);
}
void update2(int rt, int L, int R, int x) {
  if (L == R) {
    if (minn[rt] < x) minn[rt] = maxx[rt] = x;
    return;
  }
  if (minn[rt] >= x) return;
  if (maxx[rt] <= x) {
    lazy[rt] = maxx[rt] = minn[rt] = x;
    return;
  }
  pushdown(rt);
  int mid = (L + R) >> 1;
  update2(rt << 1, L, mid, x);
  update2((rt << 1) + 1, mid + 1, R, x);
  minn[rt] = min(minn[rt << 1], minn[(rt << 1) + 1]);
  maxx[rt] = max(maxx[rt << 1], maxx[(rt << 1) + 1]);
}
int query(int rt, int L, int R, int pos) {
  if (L == R) return maxx[rt];
  pushdown(rt);
  int mid = (L + R) >> 1;
  if (pos <= mid)
    return query(rt << 1, L, mid, pos);
  else
    return query((rt << 1) + 1, mid + 1, R, pos);
}
int main() {
  int n, q;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &(a[i]));
  build(1, 1, n);
  scanf("%d", &q);
  while (q--) {
    int op, x, y;
    scanf("%d", &op);
    if (op == 1) {
      scanf("%d%d", &x, &y);
      update1(1, 1, n, x, y);
    } else {
      scanf("%d", &x);
      update2(1, 1, n, x);
    }
  }
  for (int i = 1; i <= n; i++) printf("%d ", query(1, 1, n, i));
  puts("");
  return 0;
}
