-
-
Save jaapbrasser/3a2a4c35d9a478398c1de27d78dd6e24 to your computer and use it in GitHub Desktop.
The Shining carpet pattern program
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
Orginal Python: https://twitter.com/AlSweigart/status/1411893003157913603 | |
#> | |
function Show-Carpet { | |
param( | |
$X = 6, # How many times to tessellate horizontally. | |
$Y = 4 # How many times to tessellate vertically. | |
) | |
1..$Y | ForEach-Object { | |
'_ \ \ \_/ __' * $X | |
' \ \ \___/ _' * $X | |
'\ \ \_____/ ' * $X | |
'/ / / ___ \_' * $X | |
'_/ / / _ \__' * $X | |
'__/ / / \___' * $X | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment