Will this sort of thing do?
[cubescript]
fizzbuzz = [ loop i 101 [
if (&& (= (mod $i 3) 0) (= (mod $i 5) 0)) [
echo "FizzBuzz" ] [
if (= (mod $i 3) 0) [
echo "Fizz" ] [
if (= (mod $i 5) 0) [
echo "Buzz" ] [
echo $i ]
]
]
]
]
[/cubescript]
Looking at this now, I have no idea why I did it this way.
Ah, yeah, this is echo, not printf. Newlines 'n' shiz.
[cubescript]
fizzbuzz = [ loop i 101 [
if (&& (= (mod $i 3) 0) (= (mod $i 5) 0)) [
echo "FizzBuzz" ] [
if (= (mod $i 3) 0) [
echo "Fizz" ] [
if (= (mod $i 5) 0) [
echo "Buzz" ] [
echo $i ]
]
]
]
]
[/cubescript]
Looking at this now, I have no idea why I did it this way.
Ah, yeah, this is echo, not printf. Newlines 'n' shiz.