Your goal is to display ASCII art of a formation in ten-pin bowling where only some of the pins remain. Fewest bytes wins.
The tens pins are in a triangular formation:
O O O O
O O O
O O
O
Pins are labelled from 1 to 10 as:
7 8 9 10
4 5 6
2 3
1
Drawing pins as O
and missing pins as .
, the formation 1 3 5 6 9 10
is:
. . O O
. O O
. O
O
Input:
A space-separated string that lists a nonempty subset of the numbers 1 though 10 in order.
Output:
Print the corresponding formation or output it as a string with linebreaks.
The formation should be flush with the left of the screen. Any whitespace is fine as long as the visible image is correct. Empty lines before and after are fine too.
Test cases:
>> 1 2 3 4 5 6 7 8 9 10
O O O O
O O O
O O
O
>> 7 10
O . . O
. . .
. .
.
>> 3 5 7 9 10
O . O O
. O .
. O
.
>> 1
. . . .
. . .
. .
O