#include <bits/stdc++.h>
using namespace std;
int main() {
  int flag = 1, sum = 0, n, i;
  cin >> n;
  vector<int> num(n);
  vector<int> test(n);
  for (i = 0; i < n; ++i) {
    cin >> num[i];
    sum += num[i];
    test[i] = 0;
  }
  i = 0;
  while (true) {
    if (flag == 1) {
      if (test[i] < num[i]) {
        cout << "P";
        test[i]++;
        sum--;
        if (sum == 0) break;
        cout << "R";
      } else
        cout << "R";
      i++;
    }
    if (flag == 0) {
      if (test[i] < num[i]) {
        cout << "P";
        test[i]++;
        sum--;
        if (sum == 0) break;
        cout << "L";
      } else
        cout << "L";
      i--;
    }
    if (i == n - 1)
      flag = 0;
    else if (i == 0)
      flag = 1;
    if (sum == 0) break;
  }
  return 0;
}
