TIL about key-value pairs in Elixir

Today I learned, that if you want to pass key-valued list in function, you can omit the brackets, e.g:

func_name key1: "value", key2: "another value"

It will be equals to this:

func_name [key1: "value", key2: "another value"]

UPD: Thanks to Dragos Tudorache to leave a little note about it. List of tuples have to be the last argument of a function :)

Have fun and program Elixir 🍶

Software Engineer at Yandex N. V.