#include <bits/stdc++.h>
using namespace std;
int x[105];
int main() {
  int n, a, b, p;
  cin >> n >> a >> b;
  for (int i = 1; i <= a; i++) {
    int p;
    cin >> p;
    x[p] = 1;
  }
  for (int i = 1; i <= b; i++) {
    int q;
    cin >> q;
    x[q] = 2;
  }
  for (int i = 1; i <= n; i++) {
    cout << x[i] << ' ';
  }
  return 0;
}
