use std::cmp;
use std::collections::BinaryHeap;
use std::collections::HashMap;
use std::collections::HashSet;
use std::collections::VecDeque;
use std::io::Read;
use std::usize::MAX;

macro_rules! input {(source = $s:expr, $($r:tt)*) => {let mut iter = $s.split_whitespace();let mut next = || { iter.next().unwrap() };input_inner!{next, $($r)*}};($($r:tt)*) => {let stdin = std::io::stdin();let mut bytes = std::io::Read::bytes(std::io::BufReader::new(stdin.lock()));let mut next = move || -> String{bytes.by_ref().map(|r|r.unwrap() as char).skip_while(|c|c.is_whitespace()).take_while(|c|!c.is_whitespace()).collect()};input_inner!{next, $($r)*}};}
macro_rules! input_inner {($next:expr) => {};($next:expr, ) => {};($next:expr, $var:ident : $t:tt $($r:tt)*) => {let $var = read_value!($next, $t);input_inner!{$next $($r)*}};}
macro_rules! read_value {($next:expr, ( $($t:tt),* )) => {( $(read_value!($next, $t)),* )};($next:expr, [ $t:tt ; $len:expr ]) => {(0..$len).map(|_| read_value!($next, $t)).collect::<Vec<_>>()};($next:expr, chars) => {read_value!($next, String).chars().collect::<Vec<char>>()};($next:expr, usize1) => {read_value!($next, usize) - 1};($next:expr, [ $t:tt ]) => {{let len = read_value!($next, usize);(0..len).map(|_| read_value!($next, $t)).collect::<Vec<_>>()}};($next:expr, $t:ty) => {$next().parse::<$t>().expect("Parse error")};}

fn solve() {
    input! {
        n: usize,
        p: [(i64,i64);n]
    }

    let mut max_dist = p[0].0.abs() + p[0].1.abs();
    let mod2 = max_dist % 2;
    let mut ok = true;

    for i in 1..n {
        let dist = p[i].0.abs() + p[i].1.abs();
        max_dist = cmp::max(dist, max_dist);
        if (dist % 2).abs() != mod2 {
            ok = false;
            break;
        }
    }

    if !ok {
        println!("-1");
        return;
    }

    let mut arms: Vec<i64> = Vec::new();
    if mod2 == 0 {
        arms.push(1);
    }
    for i in 0..39 {
        arms.push(1 << i);
    }
    arms.reverse();

    // arm情報のprint
    println!("{}", arms.len());
    for i in 0..arms.len() {
        if i != arms.len() - 1 {
            print!("{} ", arms[i]);
        } else {
            print!("{}", arms[i]);
        }
    }
    println!("");

    for c in &p {
        let x = c.0;
        let y = c.1;

        let mut now_x = 0;
        let mut now_y = 0;

        let mut mode = String::from("");

        for a in &arms {
            let mut handle_x = true;
            let x_dist = x - now_x;
            let y_dist = y - now_y;
            if y_dist.abs() > x_dist.abs() {
                handle_x = false;
            }

            if handle_x {
                if x_dist > 0 {
                    now_x += *a;
                    mode.push('R');
                } else {
                    now_x -= *a;
                    mode.push('L');
                }
            } else {
                if y_dist > 0 {
                    now_y += *a;
                    mode.push('U');
                } else {
                    now_y -= *a;
                    mode.push('D');
                }
            }
        }

        //println!("({},{}) ({},{}) {}", now_x, now_y, x, y, mode);
        println!("{}", mode);
    }
}

fn main() {
    let thd = std::thread::Builder::new().stack_size(104_857_600);
    thd.spawn(|| solve()).unwrap().join().unwrap();

    /*
    // 入力を一括で読み込む場合
    let mut buf = String::new();
    std::io::stdin().read_to_string(&mut buf).unwrap();
    let mut input = buf.split_whitespace();

    // inputに対しnext()で読み込んでいく
    let q: usize = input.next().unwrap().parse().unwrap();
    */
}

const LARGE_PRIME: u64 = 1_000_000_007;

// @〜でsnippet


Measured memory_bytes: 8572