CF48H.Black and White
省选/NOI-
通过率:0%
时间限制:2.00s
内存限制:256MB
AC君温馨提醒
该题目为【codeforces】题库的题目,您提交的代码将被提交至codeforces进行远程评测,并由ACGO抓取测评结果后进行展示。由于远程测评的测评机由其他平台提供,我们无法保证该服务的稳定性,若提交后无反应,请等待一段时间后再进行重试。
题目描述
According to the legends the king of Berland Berl I was noted for his love of beauty and order. One day he ordered to tile the palace hall's floor where balls and receptions used to take place with black and white tiles according to a regular geometrical pattern invented by him. However, as is after the case, due to low financing there were only a black and b white tiles delivered to the palace. The other c tiles were black and white (see the picture).

The initial plan failed! Having learned of that, the king gave a new command: tile the floor with the available tiles so that no black side of a tile touched a white one. The tiles are squares of one size 1 × 1, every black and white tile can be rotated in one of the four ways.
The court programmer was given the task to work out the plan of tiling and he coped with the task and didn't suffer the consequences of disobedience. And can you cope with it?
据传说,贝尔兰国王贝尔一世以热爱美与秩序而闻名。一天,他下令按照自己设计的一种规则几何图案,用黑白瓷砖铺设宫殿大厅的地面(此处曾举办舞会和宴会)。然而,由于经费不足,运抵宫殿的瓷砖仅有 a 块黑色瓷砖和 b 块白色瓷砖,另有 c 块瓷砖为黑白两色(见下图)。

原计划因此失败!得知此事后,国王下达了新命令:使用现有瓷砖铺设地面,使得任意一块瓷砖的黑色边均不与另一块瓷砖的白色边相接触。所有瓷砖均为边长为 1×1 的正方形;每块纯黑或纯白瓷砖均可沿四个方向之一进行旋转。
宫廷程序员受命制定铺砖方案,他成功完成了任务,因而免于违命之罚。那么,你能否也完成这一任务?
输入格式
The first line contains given integers n and m (1 ≤ n, m ≤ 100) which represent the sizes of the rectangle that needs to be tiled. The next line contains non-negative numbers a, b and c, a + b + c = nm, c ≥ m.
第一行包含给定的整数 n 和 m(1≤n,m≤100),表示需要铺满的矩形的尺寸。
下一行包含三个非负整数 a、b 和 c,满足 a+b+c=nm,且 c≥m。
输出格式
Print 2_n_ lines containing 2_m_ characters each — the tiling scheme. Every tile is represented by a square 2 × 2 in the following manner (the order corresponds to the order of the picture above):

If multiple solutions exist, output any.
输出 2n 行,每行包含 2m 个字符——即铺砖方案。每块瓷砖用一个 2×2 的方块表示,方式如下(顺序与上方图片一致):

若存在多种解,输出任意一种即可。
输入输出样例
输入#1
2 2 0 0 4
输出#1
\../ #\/# \##/ .\/.
输入#2
2 3 1 2 3
输出#2
###/\# ##/..\ #/.... /.....
输入解题思路,AI测评打分。不知道怎么写?