#5342. Problem 3. The Cow-Signal

0

Problem 3. The Cow-Signal

Problem 3. The Cow-Signal

USACO 2016 December Contest, Bronze

Bessie and her cow friends are playing as their favorite cow superheroes. Of course, everyone knows that any self-respecting superhero needs a signal to call them to action. Bessie has drawn a special signal on a sheet of M×NM \times N paper (1M10,1N101 \leq M \leq 10, 1 \leq N \leq 10), but this is too small, much too small! Bessie wants to amplify the signal so it is exactly KK times bigger (1K101 \leq K \leq 10) in each direction.

The signal will consist only of the '.' and 'X' characters.

INPUT FORMAT (file cowsignal.in):

The first line of input contains MM, NN, and KK, separated by spaces.

The next MM lines each contain a length-NN string, collectively describing the picture of the signal.

OUTPUT FORMAT (file cowsignal.out):

You should output KMKM lines, each with KNKN characters, giving a picture of the enlarged signal.

SAMPLE INPUT:


5 4 2
XXX.
X..X
XXX.
X..X
XXX.

SAMPLE OUTPUT:


XXXXXX..
XXXXXX..
XX....XX
XX....XX
XXXXXX..
XXXXXX..
XX....XX
XX....XX
XXXXXX..
XXXXXX..

Problem credits: Nathan Pinsker