QOJ.ac

QOJ

时间限制: 1.0 s 内存限制: 32 MB 总分: 50

#16631. 棋盘

统计

Mirko 已经成为了一个铁杆爱国者,所以他让你帮他画一个克罗地亚棋盘(国际象棋棋盘)。

棋盘由红色和白色的格子组成。左上角的格子是红色的,其余的格子在行和列上交替呈现白色和红色。我们用字符 X(大写字母 X)表示红色区域,用字符 .(英文句号)表示白色区域。

Mirko 的棋盘应该由 $R \times C$ 个格子组成,即 $R$ 行 $C$ 列。每个格子在高度上由 $A$ 个字符组成,在宽度上由 $B$ 个字符组成。具体细节请参考下方的样例。

输入格式

第一行包含两个正整数 $R$ 和 $C$($1 \le R, C \le 10$)。

第二行包含两个正整数 $A$ 和 $B$($1 \le A, B \le 10$)。

输出格式

输出必须包含总共 $R \times A$ 行和 $C \times B$ 列,形成上述的棋盘。

样例

输入样例 1

2 4
2 2

输出样例 1

XX..XX..
XX..XX..
..XX..XX
..XX..XX

输入样例 2

5 5
2 3

输出样例 2

XXX...XXX...XXX
XXX...XXX...XXX
...XXX...XXX...
...XXX...XXX...
XXX...XXX...XXX
XXX...XXX...XXX
...XXX...XXX...
...XXX...XXX...
XXX...XXX...XXX
XXX...XXX...XXX

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.