#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const long long INFLL = 1e18;
const int MOD = 998244353;
const int MAXN = 2e5 + 5;
int n, a[MAXN], maxSuf[MAXN], t[MAXN], q;
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d", &a[i]);
  scanf("%d", &q);
  for (int i = 0; i < q; i++) {
    int e, p, x;
    scanf("%d", &e);
    if (e == 1) {
      scanf("%d %d", &p, &x);
      p--;
      a[p] = x;
      t[p] = i;
    } else {
      scanf("%d", &x);
      maxSuf[i] = x;
    }
  }
  for (int i = q - 1; i > -1; i--) maxSuf[i] = max(maxSuf[i], maxSuf[i + 1]);
  for (int i = 0; i < n; i++) {
    printf("%d", max(a[i], maxSuf[t[i]]));
    if (i == n - 1)
      printf("\n");
    else
      printf(" ");
  }
  return 0;
}
