#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 100;
int last[maxn], a[maxn];
struct node {
  int l, r, w;
};
node Tree[4 * maxn];
int arr[maxn];
void push_up(int id) {
  Tree[id].w = max(Tree[id << 1].w, Tree[id << 1 | 1].w);
  return;
}
void bulid(int l, int r, int id) {
  Tree[id].l = l;
  Tree[id].r = r;
  Tree[id].w = 0;
  if (l == r) {
    Tree[id].w = arr[l];
    return;
  }
  int mid = (l + r) / 2;
  bulid(l, mid, id << 1);
  bulid(mid + 1, r, id << 1 | 1);
  push_up(id);
}
int query(int l, int r, int id) {
  if (Tree[id].l >= l && Tree[id].r <= r) {
    return Tree[id].w;
  }
  int mid = (Tree[id].l + Tree[id].r) / 2;
  int ans = 0;
  if (l <= mid) {
    ans = query(l, r, id << 1);
  }
  if (r > mid) {
    ans = max(query(l, r, id << 1 | 1), ans);
  }
  return ans;
}
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
  }
  int q;
  scanf("%d", &q);
  for (int i = 1; i <= q; i++) {
    int type;
    scanf("%d", &type);
    if (type == 1) {
      int pos, x;
      scanf("%d%d", &pos, &x);
      a[pos] = x;
      last[pos] = i;
    } else {
      int x;
      scanf("%d", &x);
      arr[i] = x;
    }
  }
  bulid(1, q, 1);
  for (int i = 1; i <= n; i++) {
    a[i] = max(a[i], query(last[i], q, 1));
  }
  for (int i = 1; i <= n; i++) {
    if (i != n)
      printf("%d ", a[i]);
    else
      printf("%d\n", a[i]);
  }
  return 0;
}
