#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  vector<int> v(n), last(n, 0);
  for (int i = 0; i < n; i++) cin >> v[i];
  int q;
  cin >> q;
  vector<int> aux(q, 0);
  int j = 0;
  while (q--) {
    int op;
    cin >> op;
    if (op == 1) {
      int pos, x;
      cin >> pos >> x;
      last[pos - 1] = j;
      v[pos - 1] = x;
    } else {
      int x;
      cin >> x;
      aux[j] = x;
    }
    j++;
  }
  for (int i = aux.size() - 2; i >= 0; i--) aux[i] = max(aux[i], aux[i + 1]);
  for (int i = 0; i < n; i++) {
    cout << max(v[i], ((last[i] == -1) ? 0 : aux[last[i]])) << " ";
  }
}
