#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string event;
  string room = "0000000000";
  int flag = -1;
  cin >> event;
  for (int i = 0; i < n; ++i) {
    flag = -1;
    if (event.at(i) == 'L') {
      for (int j = 0; j < 10; ++j) {
        if (room.at(j) == '0') {
          if (flag < 0) flag = j;
        }
      }
      room.at(flag) = '1';
    } else if (event.at(i) == 'R') {
      for (int j = 9; j >= 0; --j) {
        if (room.at(j) == '0') {
          if (flag < 0) flag = j;
        }
      }
      room.at(flag) = '1';
    } else {
      room.at(event.at(i) - '0') = '0';
    }
  }
  cout << room << endl;
  return 0;
}
