#include <stdio.h>
#include <string.h>
#define ROW_BLOCK 4
#define COL_BLOCK 4
#define ROW_NUM (ROW_BLOCK + 2) * 2 - 1
#define COL_NUM (COL_BLOCK + 2) * 2 - 1
#define UP 0
#define RIGHT 1
#define DOWN 2
#define LEFT 3

const char command[5] = "URDL";
const int dy[4] = {-1,0,1,0}, dx[4] = {0,1,0,-1};
const int gy = 1, gx = 1;

int main(void){
	int i, j, stage[ROW_NUM][COL_NUM];
	memset(stage,0,sizeof(stage));
	for(i = 1;i < ROW_NUM - 1;i++){
		char str[ROW_BLOCK + 2];
		scanf("%s",str);
		for(j = 1 + i % 2;j < COL_NUM - 1;j+=2){
			stage[i][j] = str[(j - 1) / 2] - '0';
		}
	}
	int nd = RIGHT, nx = 1, ny = 1;
	do{
		if(stage[ny + dy[nd]][nx + dx[nd]] == 0 && stage[ny + dy[(nd + 3) % 4]][nx + dx[(nd + 3) % 4]] == 0){ // 今向いている方向に壁がなく右手にも壁がなければれば
			nd = (nd + 1) % 4;
		}else if(stage[ny + dy[(nd + 3) % 4]][nx + dx[(nd + 3) % 4]] == 1){
			nd = (nd + 3) % 4;
			ny += dy[nd] * 2;
			nx += dx[nd] * 2;
			printf("%c",command[nd]);
		}else{
			ny += dy[nd] * 2;
			nx += dx[nd] * 2;
			printf("%c",command[nd]);
		}

		/*for(i = 0;i < ROW_NUM;i++){
			for(j = 0;j < COL_NUM;j++){
				if(ny == i && nx == j){
					printf("# ");
				}else{
					printf("%d ",stage[i][j]);
				}
			}
			printf("\n");
		}
		while(getchar() != '\n');*/
	}while(!((nx == gx) && (ny == gy)));
	printf("\n");
	return 0;
}