#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 5;
struct data {
  int pos, val;
  int minx;
} a[N];
int n, last[N][2], minx, q, tot;
int find(int pos) {
  int l = 1, r = tot;
  while (r > l) {
    int mid = (l + r) >> 1;
    if (a[mid].pos < pos)
      l = mid + 1;
    else
      r = mid;
  }
  if (a[l].pos > pos)
    return a[l].minx;
  else
    return 0;
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &last[i][0]);
  scanf("%d", &q);
  int opt, p, x;
  for (int i = 1; i <= q; i++) {
    scanf("%d", &opt);
    if (opt == 1) {
      scanf("%d%d", &p, &x);
      last[p][0] = x;
      last[p][1] = i;
    } else {
      scanf("%d", &x);
      a[++tot].pos = i;
      a[tot].val = x;
    }
  }
  a[tot].minx = a[tot].val;
  for (int i = tot - 1; i >= 1; i--) a[i].minx = max(a[i].val, a[i + 1].minx);
  for (int i = 1; i <= n; i++) {
    int temp = find(last[i][1]);
    last[i][0] = max(last[i][0], temp);
  }
  for (int i = 1; i <= n; i++) cout << last[i][0] << " ";
  return 0;
}
