The article written by Konrad Hinsen talks about the many advantages of functional programming, specifically focusing on the Clojure language, which as we know is a dialect of Lisp, it was designed for the Java Virtual Machine and supports concurrency without problem.
After several weeks of programming with Clojure, I think that it is a very interesting and different language to what I am used to. As the author of the article says, functional programming varies greatly from traditional or imperative (as many people refer). From experience I can say that it is shocking change imperative languages like Python, Java or C (which are the most I have used in my courses) to a language like Clojure.
Clojure has important differences as the fact the lack of variables, the reason is that the programs are composed of functions and they do not change the state of variables because they are used to map input values to output values. In this way, we can say that the functions are the core <3 of this type of paradigm.
Another important difference is the use of recursion as a substitute for loops. The first time I heard the concept of recursion I found it very interesting and challenging at the same time, because it invites you to think in a non-traditional way, ie, using the definition of the problem go calling it with smaller instances. At first it may seem strange solve problems that had never thought recursively in other languages, however with Clojure can be very easy to solve and written in a few lines of code.
Probably concurrency and parallelism are the most important advantages, since with the evolution of technology we should take advantage of the power that computers provide us, for that reason, functional programming is considered a promise, because being a technique different then there are no coherence issues in data.
In conclusion, I hope to go slowly discovering all the wonders of this language that everyone speaks and can be the next step in evolution.
0 comentarios:
Publicar un comentario