#include <bits/stdc++.h>
template <class T>
inline void read(T &);
template <class T>
inline void write(const T &);
typedef const int &ci;
const int iinf = 2147483647;
const long long llinf = 9223372036854775807ll;
using std::abs;
using std::max;
using std::min;
using std::sort;
const int N = 200005;
int a[N];
std::pair<int, int> lasu[N];
std::pair<int, int> mu[N];
int maxu[N];
int id;
std::vector<int> v[N];
int main() {
  int n;
  read(n);
  for (int i = 1; i <= n; ++i) {
    read(a[i]);
    lasu[i] = std::pair<int, int>(id, a[i]);
  }
  int q;
  read(q);
  for (int i = 1; i <= q; ++i) {
    int mod;
    read(mod);
    if (mod == 1) {
      int p, x;
      read(p), read(x);
      lasu[p] = std::pair<int, int>(id, x);
    } else {
      int x;
      read(x);
      mu[id + 1] = std::pair<int, int>(id, x);
      ++id;
    }
  }
  for (int i = 1; i <= n; ++i) {
    v[lasu[i].first].push_back(i);
  }
  for (auto j : v[id]) {
    a[j] = lasu[j].second;
  }
  for (int i = id; i >= 1; --i) {
    maxu[i] = max(maxu[i + 1], mu[i].second);
    for (auto j : v[i - 1]) {
      a[j] = max(lasu[j].second, maxu[i]);
    }
  }
  for (int i = 1; i <= n; ++i) {
    write(a[i]), putchar(' ');
  }
  putchar('\n');
  return 0;
}
template <class T>
void read(T &Re) {
  T k = 0;
  char ch = getchar();
  int flag = 1;
  while (!(ch >= '0' && ch <= '9')) {
    if (ch == '-') {
      flag = -1;
    }
    ch = getchar();
  }
  while ((ch >= '0' && ch <= '9')) {
    k = (k << 1) + (k << 3) + ch - '0';
    ch = getchar();
  }
  Re = flag * k;
}
template <class T>
void write(const T &Wr) {
  if (Wr < 0) {
    putchar('-');
    write(-Wr);
  } else {
    if (Wr < 10) {
      putchar(Wr + '0');
    } else {
      write(Wr / 10);
      putchar((Wr % 10) + '0');
    }
  }
}
