#include <bits/stdc++.h>
using namespace std;
const long long N = 1e6 + 3;
long long n, x, a, cnt, ans, sum;
string g;
deque<long long> v;
void DNM() {
  cin >> n;
  for (long long i = 0; i < n; i++) {
    cin >> a;
    v.push_back(a);
    if (a > 0) cnt = i;
  }
  for (long long i = 0; i <= cnt; i++) {
    if (i == cnt and i == n - 1) {
      for (long long j = 1; j <= v[i]; j++) {
        if (j == v[i])
          g += 'P';
        else
          g += 'P', g += 'L', g += 'R';
      }
      break;
    }
    for (long long j = 0; j < v[i]; j++) {
      g += 'P';
      g += 'R';
      g += 'L';
    }
    g += 'R';
  }
  cout << g << endl;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  int Qu_l_uQ = 1;
  while (Qu_l_uQ--) DNM();
}
