#include <bits/stdc++.h>
long long int power(long long int x, long long int b) {
  long long int p = 1;
  while (b > 0) {
    if (b & 1) {
      p = p * x;
      p %= 1000000007;
    }
    b >>= 1;
    x *= x;
    x %= 1000000007;
  }
  return p % 1000000007;
}
using namespace std;
int main() {
  long long int n;
  cin >> n;
  vector<long long int> a(n);
  for (long long int i = 0; i < n; i++) {
    cin >> a[i];
  };
  long long int q;
  cin >> q;
  vector<long long int> d(q + 1);
  unordered_map<long long int, long long int> r;
  for (long long int i = 0; i < q; i++) {
    long long int ch;
    cin >> ch;
    if (ch == 1) {
      long long int p, x;
      cin >> p >> x;
      p--;
      a[p] = x;
      r[p] = i;
    } else {
      cin >> d[i];
    }
  }
  for (long long int i = q - 1; i >= 0; i--) d[i] = max(d[i], d[i + 1]);
  for (long long int i = 0; i < n; i++) {
    a[i] = max(a[i], d[r[i]]);
    cout << a[i] << " ";
  }
  return 0;
}
