#include <bits/stdc++.h>
using namespace std;
const int N = 250000;
long long n, q;
long long a[N], lst[N];
long long op[N];
long long p, x, y;
int main() {
  scanf("%I64d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%I64d", &a[i]);
    lst[i] = 0;
  }
  scanf("%I64d", &q);
  for (int i = 1; i <= q; i++) {
    scanf("%I64d", &y);
    if (y == 1) {
      scanf("%I64d%I64d", &p, &x);
      a[p] = x;
      lst[p] = i;
    } else {
      scanf("%I64d", &x);
      op[i] = x;
    }
  }
  for (int i = q; i >= 0; i--) {
    op[i] = max(op[i], op[i + 1]);
  }
  for (int i = 1; i <= n; i++) {
    if (a[i] < op[lst[i]]) {
      a[i] = op[lst[i]];
    }
  }
  for (int i = 1; i <= n; i++) {
    printf("%I64d%c", a[i], i == n ? '\n' : ' ');
  }
  return 0;
}
