I got a chance to do work with a Elixir Fan ;) He told me many things about this new programing language. After long conversations about this language I decided to dig in to the language. What I found is really amazing. I fall in love with this new baby. Elixir is a dynamic, functional language designed for building scalable and maintainable applications. During my programing career I do work on different language and at the end I stopped on Python. I absolutely love it and I don't necessarily plan to stop doing it.
Now days concurrency is a matter for my project and it is the thing that also lead me to Elixir. Now just write a simple Hello World in this language.
# hello.exs
defmodule Greeter do
def greet(name) do
message = "Hello, " <> name <> "!"
IO.puts message
end
end
Greeter.greet("world")
Functional programming is very different from imperative programming. The most significant differences stem from the fact that functional programming avoids side effects, which are used in imperative programming to implement state and I/O. Pure functional programming completely prevents side-effects and provides referential transparency.Higher-order functions are rarely used in older imperative programming. A traditional imperative program might use a loop to traverse and modify a list. A functional program, on the other hand, would probably use a higher-order “map” function that takes a function and a list, generating and returning a new list by applying the function to each list item.
I just found an interesting article on Elixir Lang and importance of functional programing in 2018. https://dev.to/allanmacgregor/you-should-learn-functional-programming-in-2018-4nff
Now it's time for office, more on this series will come soon. Click here for more on Elixir Language
to be continued...