#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 10;
int val[maxn], jian[maxn];
int jianp[maxn];
int jun[maxn];
int junp = -1;
int main() {
  int n, q;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &val[i]);
  scanf("%d", &q);
  memset(jian, -1, sizeof(jian));
  for (int i = 1; i <= q; i++) {
    int t;
    scanf("%d", &t);
    if (t == 1) {
      int a, b;
      scanf("%d%d", &a, &b);
      jian[a] = b;
      jianp[a] = i;
    } else {
      int a;
      scanf("%d", &a);
      jun[i] = a;
      junp = i;
    }
  }
  for (int i = q; i >= 2; i--) jun[i - 1] = max(jun[i - 1], jun[i]);
  if (junp == -1) {
    for (int i = 1; i <= n; i++) {
      if (jian[i] != -1)
        printf("%d ", jian[i]);
      else
        printf("%d ", val[i]);
    }
  } else {
    for (int i = 1; i <= n; i++) {
      if (jian[i] == -1)
        printf("%d ", max(val[i], jun[1]));
      else {
        if (jianp[i] > junp)
          printf("%d ", jian[i]);
        else
          printf("%d ", max(jian[i], jun[jianp[i] + 1]));
      }
    }
  }
}
