#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int a[n + 1];
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  int pre = 1, tr = 0;
  while (1) {
    if (a[pre] > 0) {
      if (tr == 0) {
        a[pre]--;
        tr = 1;
        cout << "P";
        continue;
      } else {
        if (pre == n) {
          cout << "LR";
          tr = 0;
          continue;
        }
        if (pre == 1) {
          cout << "RL";
          tr = 0;
          continue;
        }
        cout << "LR";
        tr = 0;
        continue;
      }
    } else {
      pre++;
      if (pre == n + 1) break;
      cout << "R";
    }
  }
  return 0;
}
