#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using vi = vector<int>;
using pi = pair<int, int>;
const int mod = 1e9 + 7;
const ll inf = ll(1e18);
const double PI = acos(-1), eps = 1e-9;
const int mxn = 2e5, mxa = 1e5;
int n, q, a[mxn + 5];
pi p[mxn + 5];
void solve() {
  cin >> n;
  for (int i = 1; i <= n; ++i) cin >> a[i];
  vector<pi> v;
  cin >> q;
  for (int tt = 1; tt <= q; ++tt) {
    int t;
    cin >> t;
    if (t == 1) {
      int i;
      cin >> i;
      p[i].first = tt;
      cin >> p[i].second;
    } else {
      int x;
      cin >> x;
      while (!v.empty() && v.back().second <= x) v.pop_back();
      v.push_back({tt, x});
    }
  }
  for (int i = 1; i <= n; ++i) {
    if (v.empty()) {
      if (p[i].first) a[i] = p[i].second;
      continue;
    }
    int lo = 0, hi = (int)(v).size();
    while (lo < hi) {
      int mid = lo + (hi - lo) / 2;
      v[mid].first < p[i].first ? lo = mid + 1 : hi = mid;
    }
    if (p[i].first) a[i] = p[i].second;
    if (lo < (int)(v).size()) a[i] = max(a[i], v[lo].second);
  }
  for (int i = 1; i <= n; ++i) cout << a[i] << ' ';
  cout << '\n';
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int t;
  t = 1;
  while (t-- > 0) solve();
}
