#include <bits/stdc++.h>
using namespace std;
int main() {
  std::ios::sync_with_stdio(false);
  std::cin.tie(0);
  int n, q;
  cin >> n;
  vector<int> a(n), last(n, -1);
  for (int i = 0; i < n; ++i) cin >> a[i];
  cin >> q;
  vector<int> t, v;
  for (int j = 0; j < q; ++j) {
    int type;
    cin >> type;
    if (type == 1) {
      int p, x;
      cin >> p >> x;
      a[p - 1] = x;
      last[p - 1] = j;
    } else {
      int x;
      cin >> x;
      t.push_back(j);
      v.push_back(x);
    }
  }
  for (int i = (int)t.size() - 2; i >= 0; --i) {
    v[i] = max(v[i], v[i + 1]);
  }
  for (int i = 0; i < n; ++i) {
    int it = lower_bound(t.begin(), t.end(), last[i]) - t.begin();
    if (it < t.size()) {
      a[i] = max(a[i], v[it]);
    }
    cout << a[i] << ' ';
  }
  cout << endl;
  return 0;
}
