#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n;
  cin >> n;
  string s;
  cin >> s;
  long long arr[10];
  for (long long i = 0; i < 10; i++) {
    arr[i] = 0;
  }
  for (long long i = 0; i < n; i++) {
    if (s[i] == 'L') {
      for (long long j = 0; j < 10; j++) {
        if (arr[j] == 0) {
          arr[j] = 1;
          break;
        }
      }
    } else if (s[i] == 'R') {
      for (long long j = 9; j >= 0; j--) {
        if (arr[j] == 0) {
          arr[j] = 1;
          break;
        }
      }
    } else {
      long long k = s[i] - '0';
      arr[k] = 0;
    }
  }
  for (long long i = 0; i < 10; i++) {
    cout << arr[i];
  }
  cout << endl;
  return 0;
}
