#include <bits/stdc++.h>
using namespace std;
bool b[10];
int main() {
  int n, t;
  cin >> n;
  string s;
  cin >> s;
  for (int i = 0; i < n; i++) {
    if (s[i] == 'L') {
      t = 0;
      while (b[t] == 1) t++;
      b[t] = 1;
    }
    if (s[i] == 'R') {
      t = 9;
      while (b[t] == 1) t--;
      b[t] = 1;
    }
    if (s[i] >= '0' && s[i] <= '9') {
      t = s[i] - '0';
      b[t] = 0;
    }
  }
  for (int i = 0; i < 10; i++) cout << b[i];
  return 0;
}
