This page is still under construction.

Parts of this page are still being built. What you see may change.

Zu

Time limit1sMemory limit256 MB

Level

Not classified yet

Solved
No attempts yet

Problem

Gomez was exploring ancient ruins when he found a stone tablet carved with the writing of an ancient people. He knows nothing about the ancient script, so he cannot read the tablet, and he is looking for someone who can read it for him. If you know the ancient writing well, help poor Gomez.

Input

The first line has two natural numbers RR and CC. (1≤R,C≤501 \le R, C \le 50)

The next 6R−16R - 1 lines hold the contents of the tablet. Each line has 6C−16C - 1 characters, and every character is # or .. Read the examples to work out the exact layout.

Output

Print the result of reading the tablet. Every hint about the output format is already given.

Examples4

  1. Example 1

    Input
    3 4
    #####.#####.#####......
    #.#.#...#...#####......
    #.###.#...#.#####......
    #...#.#####.#...#......
    #####.#####.#.#.#......
    .......................
    #####.......#####.#####
    ###.........#...#.#.#.#
    ###.#.......#.#.#.#####
    ###.........#.#.#.#.#.#
    #####.......#####.#####
    .......................
    #####.#####.......###.#
    #####.#...#.......###.#
    #####.#.#.#.......###.#
    ..###.....#.......#...#
    #.###.#####.......#.###
    
    Expected output
    _10kq
    uv3_
    a_b
    3cd
    
  2. Example 2

    Input
    1 1
    .....
    .....
    .....
    .....
    .....
    
    Expected output
    _
    
  3. Example 3

    Input
    5 1
    ###.#
    ##..#
    ##.##
    ##..#
    ###.#
    .....
    #####
    ..###
    #.###
    ..###
    #####
    .....
    #####
    #####
    #...#
    ..#..
    #####
    .....
    #####
    ..###
    #.###
    #....
    #####
    .....
    #####
    ....#
    ###.#
    ###..
    #####
    
    Expected output
    gomez
    
  4. Example 4

    Input
    1 1
    #####
    #.#.#
    #####
    #.#.#
    #####
    
    Expected output
    10