#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 10;
struct ope {
  int opt, p, x;
} a[N];
int n, q, v[N], res[N];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &v[i]);
  }
  scanf("%d", &q);
  for (int i = 1; i <= q; i++) {
    scanf("%d", &a[i].opt);
    if (a[i].opt == 1)
      scanf("%d%d", &a[i].p, &a[i].x);
    else
      scanf("%d", &a[i].x);
  }
  memset(res, -1, sizeof(res));
  int val = 0;
  for (int i = q; i >= 1; i--) {
    if (a[i].opt == 1) {
      int p = a[i].p;
      if (res[p] != -1)
        continue;
      else
        res[p] = max(a[i].x, val);
    } else {
      val = max(val, a[i].x);
    }
  }
  for (int i = 1; i <= n; i++) {
    if (res[i] != -1)
      continue;
    else
      res[i] = max(v[i], val);
  }
  for (int i = 1; i <= n; i++) {
    printf("%d ", res[i]);
  }
  return 0;
}
