Write a program or function that draws an ASCII star, given the size of the arms as input.
Here's a star of size 1
_/\_
\ /
|/\|
Here's a star of size 2
/\
__/ \__
\ /
\ /
| /\ |
|/ \|
Here's a star of size 3
/\
/ \
___/ \___
\ /
\ /
\ /
| /\ |
| / \ |
|/ \|
And so on.
Input
A single positive integer in any convenient format, n > 0
.
Output
An ASCII-art representation of a star, following the above rules. Leading/trailing newlines or other whitespace are optional, provided that the points line up appropriately.
Rules
- Either a full program or a function are acceptable. If a function, you can return the output rather than printing it.
- Standard loopholes are forbidden.
- This is code-golf so all usual golfing rules apply, and the shortest code (in bytes) wins.