#include <bits/stdc++.h>
int goal[305];
int coin[305];
int main() {
  int n;
  while (scanf("%d", &n) != EOF) {
    int sum = 0;
    memset(coin, 0, sizeof(coin));
    for (int i = 1; i <= n; i++) {
      scanf("%d", &goal[i]);
      sum += goal[i];
    }
    int dir = 1;
    for (int i = 1; sum; i += dir) {
      if (goal[i] > coin[i]) {
        putchar('P');
        coin[i]++;
        sum--;
      }
      if (sum == 0) break;
      if (i == n && dir == 1) {
        dir = -1;
      }
      if (i == 1 && dir == -1) {
        dir = 1;
      }
      if (dir == 1)
        putchar('R');
      else
        putchar('L');
    }
    puts("");
  }
  return 0;
}
