favorite We need a little bit of your help to keep things running, click on this banner to learn more
Competitions

# Character designs on fabric

Write a program for drawing patterns on the cloth as symbols. The odd lines of the pattern characters are in a row, and even - are separated by a space.

Input

In a single line of input file specified first symbol pattern S, then through the gaps 3 positive integers: the width of the pattern w (odd, w < 80), its height h (h40) and frequency t (t40). In the example, the output gap, for clarity, replaced by a point.

Output

Print the desired pattern.

Time limit 1 second
Memory limit 64 MiB
Input example #1
W 7 9 1

Output example #1
WWWWWWW
W W W W
WWWWWWW
W W W W
WWWWWWW
W W W W
WWWWWWW
W W W W
WWWWWWW

Input example #2
E 9 6 2

Output example #2
EEEEEEEEE
E E E E E
EEEEEEEEE
E E E E E
EEEEEEEEE
E E E E E
EEEEEEEEE
E E E E E
EEEEEEEEE
E E E E E
EEEEEEEEE

Source Stage II All-Ukrainian Olympiad 2010-2011 Berdichev