3 ms·
How about solution without any explicit mathematical operations, just pattern matching on decimal notation? #!/usr/bin/env rc for (i in `{seq 100}) { t
by dexen 13y ago
How about solution without any explicit mathematical operations, just pattern matching on decimal notation?
#!/usr/bin/env rc
for (i in `{seq 100}) {
toPrint = $i
toPost = ''
if (~ $i *5 || ~ $i *0 ) {
toPrint = Buzz
toPost = Buzz }
if (~ $i ([369] [147][258] [258][147] [369][0369]))
toPrint = Fizz ^ $toPost
echo $toPrint
}