#include <bits/stdc++.h>
using namespace std;
const int64_t mod = 998244353;
int64_t mul(int64_t a, int64_t b) { return a * b % mod; }
int64_t add(int64_t a, int64_t b) { return (a + b) % mod; }
int64_t bpow(int64_t x, int64_t n) {
  return n ? n % 2 ? x * bpow(x, n - 1) % mod : bpow(x * x % mod, n / 2) : 1;
}
signed main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int64_t n;
  cin >> n;
  int64_t a[n], b[n];
  for (int64_t i = 0; i < n; i++) {
    cin >> a[i];
    b[i] = -1;
  }
  int64_t q;
  cin >> q;
  vector<int64_t> last = {0}, val = {0};
  for (int64_t i = 0; i < q; i++) {
    int64_t t;
    cin >> t;
    if (t == 1) {
      int64_t p, x;
      cin >> p >> x;
      a[p - 1] = x;
      b[p - 1] = i;
    } else {
      int64_t x;
      cin >> x;
      last.push_back(i);
      val.push_back(x);
    }
  }
  int64_t m = last.size();
  vector<int64_t> rev(m);
  rev.back() = val.back();
  for (int64_t i = m - 2; i >= 0; i--) {
    rev[i] = max(rev[i + 1], val[i]);
  }
  for (int64_t i = 0; i < n; i++) {
    if (b[i] >= last.back()) {
      cout << a[i] << ' ';
    } else {
      auto it = lower_bound(begin(last), end(last), b[i]) - begin(last);
      cout << max(a[i], rev[it]) << ' ';
    }
  }
  return 0;
}
