#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int T = 1;
  for (int qq = 1; qq <= T; qq++) {
    long long int n;
    cin >> n;
    vector<long long int> v(n + 1);
    for (int i = 1; i <= n; i++) cin >> v[i];
    long long int q;
    cin >> q;
    vector<long long int> chng(n + 1);
    vector<long long int> qr(q);
    for (int i = 0; i < q; i++) {
      long long int x, y, z;
      cin >> x >> y;
      if (x == 1) {
        cin >> z;
        v[y] = z;
        chng[y] = i;
        qr[i] = -1;
      } else {
        qr[i] = y;
      }
    }
    for (int i = q - 2; i >= 0; i--) {
      qr[i] = max(qr[i + 1], qr[i]);
    }
    for (int i = 1; i <= n; i++) {
      cout << max(v[i], qr[chng[i]]) << ' ';
    }
    cout << endl;
  }
  return 0;
}
