#include <bits/stdc++.h>
using namespace std;
const int MAX_N = 101;
const int MOD = 1e9 + 7;
const int INF = 1e9;
const long long LINF = 1e18;
void solve() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < n; ++i) {
    cin >> a[i];
  }
  int q;
  cin >> q;
  vector<int> next(n);
  vector<int> queries;
  for (int j = 0; j < q; ++j) {
    int t;
    cin >> t;
    if (t == 1) {
      int p, x;
      cin >> p >> x;
      a[p - 1] = x;
      next[p - 1] = j + 1;
      queries.push_back(-1);
    } else {
      int x;
      cin >> x;
      queries.push_back(x);
    }
  }
  vector<int> suff(q + 1);
  for (int j = q - 1; j >= 0; --j) {
    if (queries[j] == -1)
      suff[j] = suff[j + 1];
    else
      suff[j] = max(suff[j + 1], queries[j]);
  }
  for (int i = 0; i < n; ++i) {
    cout << max(a[i], suff[next[i]]) << " ";
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int t = 1;
  while (t--) solve();
}
