#include <bits/stdc++.h>
using namespace std;
const int hashP = 239017;
const int N = 1e5 + 10;
const int MOD = 1e9 + 7;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  vector<pair<int, int> > a(n);
  for (auto& now : a) cin >> now.first;
  int q;
  cin >> q;
  vector<int> d(q + 11);
  int mx = 0, last = 0;
  for (int i = 0; i < q; i++) {
    int ch = 0;
    cin >> ch;
    if (ch == 1) {
      int x, p;
      cin >> p >> x;
      a[p - 1].first = x;
      a[p - 1].second = i + 1;
    } else {
      int x;
      cin >> x;
      d[i + 1] = x;
    }
  }
  for (int i = q - 1; i >= 0; i--) d[i] = max(d[i], d[i + 1]);
  for (auto now : a) {
    cout << max(now.first, d[now.second]) << " ";
  }
  return 0;
}
