#define _CRT_SECURE_NO_WARNINGS
#pragma comment(linker, "/STACK:256000000")
#define _USE_MATH_DEFINES
#include<iostream>
#include<vector>
#include<string>
#include<stack>
#include<algorithm>
#include<cmath>
#include<set>
#include<queue>
#include<sstream>
#include<utility>
#include<map>
#include<ctime>
#include<cstdio>
#include<cassert>
#include<functional>




using namespace std;

typedef long long ll;
typedef long double ld;
typedef unsigned int uint;
typedef unsigned long long ull;
typedef pair<ll, ll> pll;
typedef pair<int, int> pii;
typedef pair<char, char> pcc;
typedef pair<double, double> pdd;

#define show(x) cerr << x
#define debug(x) show(#x << ": " << (x) << endl)

const long double PI = 3.14159265358979323846;
const long double eps = 1e-5;
const int INF = numeric_limits<int>::max();
const ll LINF = numeric_limits<ll>::max();
const ll mod = 1000 * 1000 * 1000 + 7;


bool ok(const pll& p, ll up) {
    return abs(p.first) + abs(p.second) <= up;
}

void solve3(const vector<ll>& a, const vector<ll>& up, const vector<pii>& q) {
    int n = q.size();
    int m = a.size();
    for (int i = 0; i < n; ++i) {
        string s = "";
        pll p = q[i];
        for (int j = m - 1; j >= 0; --j) {
            pll pl(p.first - a[j], p.second);
            pll pr(p.first + a[j], p.second);
            pll pu(p.first, p.second + a[j]);
            pll pd(p.first, p.second - a[j]);
            if (ok(pl, up[j])) {
                s.push_back('R');
                p = pl;
                continue;
            }
            if (ok(pr, up[j])) {
                s.push_back('L');
                p = pr;
                continue;
            }
            if (ok(pu, up[j])) {
                s.push_back('D');
                p = pu;
                continue;
            }
            if (ok(pd, up[j])) {
                s.push_back('U');
                p = pd;
                continue;
            }
        }
        reverse(s.begin(), s.end());
        cout << s << "\n";
        //cout << p.first << " " << p.second << endl;
    }
}


void solve0(const vector<pii>& p) {
    int n = p.size();
    int m = 40;
    vector<ll> a(m);
    a[0] = a[1] = 1;
    for (int i = 2; i < m; ++i)
        a[i] = a[i - 1] * 2;
    vector<ll> up(m + 1);
    up[0] = 0;
    up[1] = 1;
    for (int i = 2; i <= m; ++i) {
        up[i] = 2 * up[i - 1];
    }
    cout << m << endl;
    for (int i = 0; i < m; ++i)
        cout << a[i] << " ";
    cout << endl;
    solve3(a, up, p);

}

void solve1(const vector<pii>& p) {
    int n = p.size();
    int m = 40;
    vector<ll> a(m);
    a[0] = 1;
    for (int i = 1; i < m; ++i)
        a[i] = a[i - 1] * 2;
    vector<ll> up(m + 1);
    up[0] = 0;
    up[1] = 1;
    for (int i = 2; i <= m; ++i) {
        up[i] = 2 * up[i - 1] + 1;
    }
    cout << m << endl;
    for (int i = 0; i < m; ++i)
        cout << a[i] << " ";
    cout << endl;
    solve3(a, up, p);
    
}




void solve() {
    int n;
    cin >> n;
    vector<pii> p(n);
    for (int i = 0; i < n; ++i) {
        cin >> p[i].first >> p[i].second;
    }
    int c = (p[0].first + p[0].second) & 1;
    for (int i = 0; i < n; ++i) {
        if ((p[i].first + p[i].second + c) & 1) {
            cout << -1 << endl;
            return;
        }
    }
    if (c == 0)
        solve0(p);
    else
        solve1(p);
    

}

//#define LOCAL

int main() {
    ios_base::sync_with_stdio(0);
#ifdef LOCAL
    freopen("input.txt", "r", stdin);
    //freopen("output.txt", "w", stdout);
#endif
    solve();


#ifdef LOCAL
    cerr << "Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " s.\n";
#endif	
    return 0;
}

Measured memory_bytes: 256