#include <bits/stdc++.h>
using namespace std;
pair<int, int> events[200000];
int a[200001];
bool visit[200001];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  int q;
  scanf("%d", &q);
  for (int i = 0; i < q; i++) {
    int c;
    scanf("%d", &c);
    if (c == 1)
      scanf("%d%d", &events[i].first, &events[i].second);
    else {
      events[i].first = 0;
      scanf("%d", &events[i].second);
    }
  }
  int m = 0;
  for (int i = q - 1; i >= 0; i--) {
    if (events[i].first) {
      if (visit[events[i].first]) continue;
      visit[events[i].first] = true;
      a[events[i].first] = max(m, events[i].second);
    } else
      m = max(m, events[i].second);
  }
  for (int i = 1; i <= n; i++)
    if (!visit[i]) a[i] = max(a[i], m);
  for (int i = 1; i <= n; i++) printf("%d ", a[i]);
  puts("");
}
