#include <bits/stdc++.h>
bool boo[10];
using namespace std;
int main() {
  long long int n;
  cin >> n;
  string a;
  cin >> a;
  string room = "0000000000";
  for (int t = 0; t < n; t++) {
    if (a[t] == 'L') {
      for (int i = 0; i < 10; i++) {
        if (boo[i] == 0) {
          room[i] = '1';
          boo[i] = 1;
          break;
        }
      }
    }
    if (a[t] == 'R') {
      for (int i = 9; i >= 0; i--) {
        if (boo[i] == 0) {
          room[i] = '1';
          boo[i] = 1;
          break;
        }
      }
    }
    for (int y = 0; y <= 9; y++) {
      if (a[t] - '0' == y) {
        room[y] = '0';
        boo[y] = 0;
        break;
      }
    }
  }
  cout << room;
}
