#include<cstdio>
#include<cmath>
#include<algorithm>
#include<cstdio>
#include<cmath>
#include<iostream>
#include<string>

using namespace std;


void Solution()
{
    long i,j,k;
    
    string s[9]; //use string instead of int type
    
    for(int i=0; i<9; i++)
    {
        cin>>s[i];
    }
    
    i = j = k = 0;
    
    cout<<"R";
    
    j++;
    
    for(;;) // infinite loop
    {
        //algorithm
        if(k == 0 && i > 0 && s[i - 1][j] == '1')
        {
            cout<<"U";
            i -= 2;
            k = 3;
        }
        else if(k == 0 && s[i][j] == '1')
        {
            cout<<"R";
            j++;
            k = 0;
        }
        else if(k == 0 && i < 8 && s[i + 1][j] == '1')
        {
            cout<<"D";
            i += 2;
            k = 1;
        }
        else if(k == 0)
        {
            cout<<"L";
            j--;
            k = 2;
        }
        else if(k == 1 && s[i][j] == '1')
        {
            cout<<"R";
            j++;
            k = 0;
        }
        else if(k == 1 && i < 8 && s[i + 1][j] == '1')
        {
            cout<<"D";
            i += 2;
            k = 1;
        }
        else if(k == 1 && j > 0 && s[i][j - 1] == '1')
        {
            cout<<"L";
            j--;
            k = 2;
        }
        else if(k == 1)
        {
            cout<<"U";
            i -= 2;
            k = 3;
        }
        else if(k == 2 && i < 8 && s[i + 1][j] == '1')
        {
            cout<<"D";
            i += 2;
            k = 1;
        }
        else if(k == 2 && j > 0 && s[i][j - 1] == '1')
        {
            cout<<"L";
            j--;
            k = 2;
        }
        else if(k == 2 && i > 0 && s[i - 1][j] == '1')
        {
            cout<<"U";
            i -= 2;
            k = 3;
        }
        else if(k == 2)
        {
            cout<<"R";
            j++;
            k = 0;
        }
        else if(k == 3 && j > 0 && s[i][j - 1] == '1')
        {
            cout<<"L";
            j--;
            k = 2;
        }
        else if(k == 3 && i > 0 && s[i - 1][j] == '1')
        {
            cout<<"U";
            i -= 2;
            k = 3;
        }
        else if(k == 3 && s[i][j] == '1')
        {
            cout<<"R";
            j++;
            k = 0;
        }
        else if(k == 3)
        {
            cout<<"D";
            i += 2;
            k = 1;
        }
        
        if(i == 0 && j == 0)
        {
            break;
        }
    }
    
    cout<<endl;
    
}

int main()
{
    Solution();
    return 0;
}