#include <bits/stdc++.h>
using namespace std;
const int maxn = 110;
int a, b, c, ar[maxn], al[maxn];
bool gg = false;
int main() {
  cin >> a >> b >> c;
  for (int i = 0; i < b; i++) cin >> ar[i];
  for (int j = 0; j < c; j++) cin >> al[j];
  for (int i = 1; i <= a; i++) {
    for (int j = 0; j < b; j++) {
      if (ar[j] == i) gg = true;
    }
    gg ? cout << 1 << " " : cout << 2 << " ";
    gg = false;
  }
  cout << endl;
  return 0;
}
