#include <bits/stdc++.h>
using namespace std;
int main() {
  short int n;
  cin >> n;
  short int a[n];
  int total = 0, count = 0;
  for (int i = 0; i < n; ++i) {
    cin >> a[i];
    total += a[i];
  }
  short int i = 0;
  while (count < total) {
    if (a[i] == 0 && i != n - 1) {
      ++i;
      cout << "R";
    } else if (a[i] > 0 && i != n - 1) {
      --a[i++];
      ++count;
      cout << "PR";
    } else if (a[i] > 0 && i == n - 1) {
      --a[i--];
      ++count;
      cout << "PL";
    }
    if (a[i - 1] > 0) {
      --i;
      cout << "L";
    }
  }
  return 0;
}
