Java drastically changed with the introduction of Java 8, and this change has been elevated to a whole new level with the new version, Java 9. Java has a well-established past, being more than 20 years old, but at the same time, it is new, functional, reactive, and sexy. This is a language that developers love, and at the same time, it is the number one choice of developer language for many enterprise projects.
It is probably more lucrative to learn Java now than ever before, starting with Java 9. We encourage you to start your professional developer career by learning Java 9, and we have done our best in this book to help you along this road. We assembled the topics of the book so that it is easy to start, and you can feel the things working and moving very soon. At the same time, we have tried to reach very far, signaling the road ahead for a professional developer.
The sands of time kept moving, and I discovered functional programming.
I could very well see why writing side-effect-free code worked! I was hooked and started playing with Scala, Clojure, and Erlang. Immutability was the norm here.
However, I wondered how traditional algorithms would look in a functional setting and started learning about it.
A data structure is never mutated in place. Instead, a new version of the data structure is created. The strategy of copy and write with maximized sharing was an intriguing one! All that careful synchronization is simply not needed!
The languages come equipped with garbage collection. So, if a version is not needed anymore, runtime would take care of reclaiming the memory.
All in good time, though! Reading this book will help you see that we need not sacrifice algorithmic performance while avoiding in-place mutation!