#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
using namespace std;
const int maxn = 2e5 + 100;
const int MAX = 1e2 + 10;
int n, v[maxn];
pair<int, pair<int, int> > qs[maxn];
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) cin >> v[i];
  int q;
  cin >> q;
  for (int i = 0; i < q; i++) {
    cin >> qs[i].first;
    if (qs[i].first == 1)
      cin >> qs[i].second.first >> qs[i].second.second;
    else
      cin >> qs[i].second.first;
  }
  int a, b, c;
  set<int> st;
  int larg = 0;
  for (int i = q - 1; i >= 0; --i) {
    a = qs[i].first, b = qs[i].second.first, c = qs[i].second.second;
    if (a == 2)
      larg = max(larg, b);
    else {
      if (c < larg and st.count(b - 1) == 0) {
        v[b - 1] = larg;
      } else if (st.count(b - 1) == 0) {
        v[b - 1] = c;
      }
      st.insert(b - 1);
    }
  }
  for (int i = 0; i < n; i++) {
    if (v[i] < larg and st.count(i) == 0) v[i] = larg;
  }
  for (int i = 0; i < n; i++) cout << v[i] << ' ';
  cout << '\n';
  return 0;
}
