#include <bits/stdc++.h>
using namespace std;
int main() {
  int arr[101];
  int n, a, b, u;
  cin >> n >> a >> b;
  for (int i = 0; i < a; i++) {
    cin >> u;
    arr[u - 1] = 1;
  }
  for (int i = 0; i < b; i++) {
    cin >> u;
    arr[u - 1] = 2;
  }
  for (int i = 0; i < n; i++) {
    cout << arr[i] << " ";
  }
  cout << endl;
}
