Skip to content

Instantly share code, notes, and snippets.

@mhoffman
Created July 11, 2018 02:45
Show Gist options
  • Save mhoffman/0c565f2ccc2b33961b9ea5785be8abd9 to your computer and use it in GitHub Desktop.
Save mhoffman/0c565f2ccc2b33961b9ea5785be8abd9 to your computer and use it in GitHub Desktop.
#!/usr/bin/env scala -savecompiled
for (i <- 1 to 15) {
if (i % 15 == 0 ){
println("FizzBuzz")
} else if (i % 5 == 0) {
println("Buzz")
} else if (i % 3 == 0) {
println("Fizz")
} else {
println(i)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment