[erlang-questions] Question about reverse list of recursion functions

Ivan Uemlianin ivan@REDACTED
Sun Dec 27 10:10:57 CET 2015

Dear Andrey
Using lists:reverse/1 is normal practice. The lists functions are implemented in
C and are fast. I think some of them also do non-erlangy cheats, eg, reverse
reverses the list "in place".
Best wishes


On Sun, Dec 27, 2015 at 3:38 am, Andrey Koleshko <ka8725@REDACTED> wrote:
Hi, guys! I recently started to learn Erlang (migrating from Ruby) by reading
“Erlang Programming” Cesarini book. After the 3rd chapter there is a task to
implement quick sort and I implemented it like this: [https://gist.github.com/ka8725/f3fcc264e12bcefa6035] https://gist.github.com/ [https://gist.github.com/] ka8725 /f3fcc264e12bcefa6035
It works well, but I have a question that doesn’t allow to sleep me - is it
normal practice to do ` reverse ` every time when you have an list with opposed direction after a few recursions
calls? Is there are other practice to avoid it? Thanks!
________________ Best Regards, Andrey Koleshko ka8725@REDACTED [ka8725@REDACTED]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20151227/38c063a8/attachment.htm>

More information about the erlang-questions mailing list