One day, GFRIEND members went to a Go club to perform their song and learn how to play Go.
[video]output.mp4[/video]
To teach them the basic rules of Go, the master gave them $$$N$$$ white stones and $$$M$$$ black stones. He then ask them to use the white stones to surround the black stones on the standard 19x19 Go board. The arrangement must satisfy the followings:
The above rules can also be expressed by the followings:
Help GFRIEND by writing a program to find out if there is a possible arrangement, and if there is, output any one.
The input consists of 2 integers $$$N$$$ and $$$M$$$.
$$$1 \le N, M \le 80$$$.
If there is no possible arrangement that satisfies the rules, output Impossible.
Otherwise, output a 19x19 grid that contains any valid arrangement. Use . to represent empty space, o to represent white stone and x to represent black stone.
20 25
...................
...................
...................
...................
...................
...................
...................
...................
...................
...................
..........ooooo....
.........oxxxxxo...
.........oxxxxxo...
.........oxxxxxo...
.........oxxxxxo...
.........oxxxxxo...
..........ooooo....
...................
...................
21 10
...................
...................
...................
...ooo.............
..oxxxo............
...ooxo............
.....o.............
.........o..o......
........oxooxo.....
........oxxxxo.....
.........oooo......
...................
...................
...................
...................
...................
...................
...................
...................
5 2
Impossible