#include <bits/stdc++.h>
const double PI = acos(-1);
template <class A, class B>
std::ostream& operator<<(std::ostream& st, const std::pair<A, B> p) {
  st << "(" << p.first << ", " << p.second << ")";
  return st;
}
using namespace std;
const int MAX = 200 * 1000 + 10, MAXB = 500;
int A[MAX], n;
int flag[MAX], m;
int Q;
int main() {
  scanf("%d", &n);
  for (int i = 0; i < (n); i++) scanf("%d", A + i);
  int B = sqrt(n) + 2;
  m = (n - 1) / B + 1;
  scanf("%d", &Q);
  while (Q--) {
    int t;
    scanf("%d", &t);
    if (t == 1) {
      int p, x;
      scanf("%d %d", &p, &x);
      p--;
      int u = p / B;
      int s = u * B, e = min(s + B, n);
      for (int i = s; i < e; i++) A[i] = max(A[i], flag[u]);
      A[p] = x;
      flag[u] = 0;
    } else {
      int x;
      scanf("%d", &x);
      for (int u = 0; u < m; u++) flag[u] = max(flag[u], x);
    }
  }
  for (int i = 0; i < (n); i++)
    printf("%d%c", max(A[i], flag[i / B]), " \n"[i == n - 1]);
  return 0;
}
