mirror of
https://github.com/yhirose/cpp-peglib.git
synced 2024-11-14 15:05:29 +00:00
18 lines
239 B
Plaintext
18 lines
239 B
Plaintext
/*
|
|
* Fizz Buzz
|
|
*/
|
|
|
|
mut i = 1
|
|
while i < 24 {
|
|
if i % 15 == 0 {
|
|
puts('FizzBuzz')
|
|
} else if i % 5 == 0 {
|
|
puts('Buzz')
|
|
} else if i % 3 == 0 {
|
|
puts('Fizz')
|
|
} else {
|
|
puts(i)
|
|
}
|
|
i = i + 1
|
|
}
|