#include <bits/stdc++.h>
using namespace std;
const unsigned long long p1 = 131;
const unsigned long long p2 = 129;
const double eps = 1e-8;
const double pi = acos(-1.0);
const int infi = 2 * 1e9;
const long long inf = 9223372036854775807;
const long long dd = 1e3 + 7;
const long long MOD = 998244353;
int main() {
  ios_base::sync_with_stdio(0);
  ;
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  int q;
  cin >> q;
  vector<int> queries(2 * 1e5 + 2), val(2 * 1e5 + 2), ind(2 * 1e5 + 2);
  int i = 0;
  int q1 = q;
  while (q--) {
    cin >> queries[i];
    if (queries[i] == 1) {
      int y, z;
      cin >> y >> z;
      y--;
      a[y] = z;
      ind[y] = i;
    } else {
      int y;
      cin >> y;
      val[i] = y;
    }
    i++;
  }
  int maxx = -infi;
  for (int i = q1 - 1; i >= 0; i--) val[i] = max(val[i], val[i + 1]);
  for (int i = 0; i < n; i++) {
    cout << max(a[i], val[ind[i]]) << " ";
  }
  return 0;
}
