#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a, b;
  cin >> n >> a >> b;
  int x[a], y[b];
  for (int r = 0; r < a; r++) {
    cin >> x[r];
  }
  sort(x, x + a);
  for (int i = 0; i < b; i++) {
    cin >> y[i];
  }
  sort(y, y + b);
  for (int k = 1; k <= n; k++) {
    int p = 0;
    for (int i = 0; i < a; i++) {
      if (x[i] == k && p == 0) {
        p = 1;
        cout << "1"
             << " ";
      }
    }
    if (p == 0) {
      cout << "2"
           << " ";
    }
  }
  return 0;
}
