I am a Developer Advocate for Security in Mobile Apps and APIs at approov.io.
Another passion is the Elixir programming language that was designed to be concurrent, distributed and fault tolerant.
Location
Scotland
Education
Self teached Developer
Work
Developer Advocate for Mobile and API Security at approov.io
They are very nice people and will help you in your journey.
I am not doing the advent of code... unfortunately I don't have spare time to dedicate to it.
TIP: while if else exists in Elixir is barely used by a functional programmer. Instead try to use pattern matching in the function heads. See here an example dev.to/flatironschool/pattern-matc...
They are very nice people and will help you in your journey.
Nice to know! I still haven't completely ruled out Clojure :D
I am not doing the advent of code... unfortunately I don't have spare time to dedicate to it.
It's perfectly fine, it's my first time ever!
TIP: while if else exists in Elixir is barely used by a functional programmer. Instead try to use pattern matching in the function heads.
Thanks for the tip. I'll surely read it. I tried to use pattern matching with MapSet.member? as a guard but it wasn't allowed, so I switched to a recursion first and then the if + reduce_while version.
I hope I'll have time to study the language a little better, not just try to butt my head on the wall until I get a decent solution :D
I am a Developer Advocate for Security in Mobile Apps and APIs at approov.io.
Another passion is the Elixir programming language that was designed to be concurrent, distributed and fault tolerant.
Location
Scotland
Education
Self teached Developer
Work
Developer Advocate for Mobile and API Security at approov.io
Not everything can go in guard clauses. Try to read about them.
I am seeing some doing the advent of code in 2 languages at same time. So why not Elixir and Clojure for solving each day challenge?
No matter what language you want to use for the advent of code would have been good that you had time to prepare for it before, like going through the basics of it.
What worked better for me to left the imperative thinking and adopt the functional programming way was this video course and this book. They are paid but totally worth every cent I paid for them. The author spent a lot of time ensuring that we understand the functional programming paradigm. By the end we have built something useful that we can use in our day to day as developers.
Try to follow the advent of code in Elixir forum elixirforum.com/t/advent-of-code-2..., they are sharing their solutions there. The solution from member Sneako seems a good one, check it elixirforum.com/t/advent-of-code-2....
They are very nice people and will help you in your journey.
I am not doing the advent of code... unfortunately I don't have spare time to dedicate to it.
TIP: while if else exists in Elixir is barely used by a functional programmer. Instead try to use pattern matching in the function heads. See here an example dev.to/flatironschool/pattern-matc...
yeah, I ended with a similar solution github.com/rhymes/aoc2018/blob/mas... - though you can see how more imperative is my code
Nice to know! I still haven't completely ruled out Clojure :D
It's perfectly fine, it's my first time ever!
Thanks for the tip. I'll surely read it. I tried to use pattern matching with
MapSet.member?
as a guard but it wasn't allowed, so I switched to a recursion first and then theif
+reduce_while
version.I hope I'll have time to study the language a little better, not just try to butt my head on the wall until I get a decent solution :D
Nice you have been able to figure it out.
Not everything can go in guard clauses. Try to read about them.
I am seeing some doing the advent of code in 2 languages at same time. So why not Elixir and Clojure for solving each day challenge?
No matter what language you want to use for the advent of code would have been good that you had time to prepare for it before, like going through the basics of it.
What worked better for me to left the imperative thinking and adopt the functional programming way was this video course and this book. They are paid but totally worth every cent I paid for them. The author spent a lot of time ensuring that we understand the functional programming paradigm. By the end we have built something useful that we can use in our day to day as developers.
Thank you :-) You're right, I should have gone through at least the tutorial before, but I totally forgot about it :D