#include <bits/stdc++.h>
using namespace std;
long long a, b, c, x[305], y;
int main() {
  cin >> a;
  y = 0;
  for (b = 1; b <= a; b++) {
    cin >> x[b];
    y = y + x[b];
  }
  for (c = 1; c <= 10000; c++) {
    for (b = 1; b < a; b++) {
      if (y > 0) {
        if (x[b] > 0) {
          cout << "P";
          y--;
          x[b]--;
          if (b + 1 <= a && y > 0) cout << "R";
        } else if (x[b] == 0)
          cout << "R";
      }
    }
    for (b = a; b > 1; b--) {
      if (y > 0) {
        if (x[b] > 0) {
          cout << "P";
          y--;
          x[b]--;
          if (b - 1 >= 1 && y > 0) cout << "L";
        } else if (x[b] == 0)
          cout << "L";
      }
    }
    if (y < 1) break;
  }
  cout << endl;
  return 0;
}
