#include <bits/stdc++.h>
using namespace std;
const long long int inf = LLONG_MAX;
long long int get() {
  long long int x;
  cin >> x;
  return x;
}
void getl(long long int* ar, long long int sz) {
  for (long long int i = 0; i < sz; i++) cin >> ar[i];
}
template <typename T>
void print(T x) {
  cout << x << "\n";
}
template <typename T>
void prints(T x) {
  cout << x << " ";
}
const long long int mod = 1e9 + 7;
const long long int N = 2e5 + 2;
long long int n, q;
long long int a[N];
long long int u[N];
long long int mp[N];
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  n = get();
  getl(a, n);
  q = get();
  for (long long int i = 0; i < q + 1; ++i) {
    mp[i] = -1;
  }
  for (long long int i = 0; i < q; ++i) {
    long long int x = get();
    if (x == 1) {
      long long int j = get() - 1;
      long long int p = get();
      a[j] = p;
      u[j] = i;
    } else {
      long long int p = get();
      mp[i] = p;
    }
  }
  for (long long int i = q - 1; i >= 0; --i) {
    mp[i] = max(mp[i], mp[i + 1]);
  };
  ;
  ;
  for (long long int i = 0; i < n; ++i) {
    cout << max(a[i], mp[u[i]]) << " ";
  }
  return 0;
}
