Another update from ingydotnet^djgoku
This commit is contained in:
parent
91df62d461
commit
948b86eafa
7604 changed files with 108452 additions and 22726 deletions
|
|
@ -1,12 +1,8 @@
|
|||
Enum.each 1..100, fn x ->
|
||||
IO.puts(case { rem(x, 5) == 0, rem(x,3) == 0 } do
|
||||
{ true, true } ->
|
||||
"FizzBuzz"
|
||||
{ true, false } ->
|
||||
"Fizz"
|
||||
{ false, true } ->
|
||||
"Buzz"
|
||||
{ false, false } ->
|
||||
x
|
||||
IO.puts(case { rem(x,3) == 0, rem(x,5) == 0 } do
|
||||
{ true, true } -> "FizzBuzz"
|
||||
{ true, false } -> "Fizz"
|
||||
{ false, true } -> "Buzz"
|
||||
{ false, false } -> x
|
||||
end)
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue