News for hackers. Stuff that matters.
Re:Happy Birthday, Ruby by dnautics on Thursday January 10, 2019 @04:41PM (#18878507)
as per Jpakotal's comment elsewhere this might be even prettier:

    1..100
    |> Enum.map_join("\n", fn 
      int when rem(int, 15) == 0 -> "FizzBuzz"
      int when rem(int, 5)  == 0 -> "Fizz"
      int when rem(int, 3)  == 0 -> "Buzz"
      int                        -> inspect int
    end)
    |> IO.puts

There are no comments on this comment yet.