#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
ll n,a,b;

ll dfs(ll d,ll h){
  if(d==n)return b;
  ll H=(1LL<<(n-1-d));
  ll W=(1LL<<d);
  if(h<H){
    ll f=dfs(d+1,H-1-h);
    printf( f<W ? "L" : "R" );
    return W-(f%W)-1;
  }else{
    ll f=dfs(d+1,h-H);
    if( f < W ){
      printf("R");
      return f;
    }else{
      printf("L");
      return f-W;
    }
  }
}

int main(){
  while(1){
    scanf("%lld %lld %lld",&n,&a,&b);
    if(n==0&&a==0&&b==0)break;
    a--;
    b--;
    dfs(0,a);
    printf("\n");
  }
  return 0;
}