#include <bits/stdc++.h>
using namespace std;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
const long long base = 1e9 + 7;
const long long oo = 2e5 + 10;
long long n, m, k;
long long a[oo];
long long max2[oo];
long long pos[oo];
int32_t main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  if (ifstream("test.txt")) {
    freopen("test.txt", "r", stdin);
  } else if (ifstream(""
                      ".inp")) {
    freopen(
        ""
        ".inp",
        "r", stdin);
    freopen(
        ""
        ".out",
        "w", stdout);
  }
  cin >> n;
  for (long long i = 1; i <= n; ++i) cin >> a[i];
  cin >> m;
  long long type, x, y;
  for (long long i = 1; i <= m; ++i) {
    cin >> type;
    if (type == 1) {
      cin >> x >> y;
      a[x] = y;
      pos[x] = i;
    } else {
      cin >> x;
      max2[i] = x;
    }
  }
  for (long long i = m; i >= 0; --i) {
    max2[i] = max(max2[i], max2[i + 1]);
  }
  for (long long i = 1; i <= n; i++) {
    cout << max(a[i], max2[pos[i]]) << " ";
  }
}
