Character designs on fabric
Easy
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
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 (h ≤ 40) and frequency t (t ≤ 40). In the example, the output gap, for clarity, replaced by a point.
Output
Print the desired pattern.
Examples
Input #1
Answer #1
Input #2
Answer #2
Submissions 624
Acceptance rate 25%