#include <bits/stdc++.h>
using namespace std;
void left(vector<int> &v);
void right(vector<int> &v);
int main() {
  int n;
  cin >> n;
  string str;
  cin >> str;
  vector<int> v(10, 0);
  for (int i = 0; i < n; i++) {
    if (str[i] == 'L') {
      left(v);
    } else if (str[i] == 'R') {
      right(v);
    } else {
      v[str[i] - '0'] = 0;
    }
  }
  for (int i = 0; i < 10; i++) {
    cout << v[i];
  }
}
void left(vector<int> &v) {
  for (int i = 0; i < 10; i++) {
    if (v[i] == 0) {
      v[i] = 1;
      return;
    }
  }
}
void right(vector<int> &v) {
  for (int i = 9; i >= 0; i--) {
    if (v[i] == 0) {
      v[i] = 1;
      return;
    }
  }
}
