Learning Erlang
Today I was in a mood to learn something totally different; something which I haven’t tried so far; something which is totally new to my programming mind. I have heard and knew Scala, Erlang, Haskell, Clojure etc are the best contenders. I decided I will try Scala and Clojure later only after get into grips with some Java and LISP, since they run on JVM and one is a newway of doing LISP (I know the thought is faulty and we need not necessarily know Java and LISP before diving it, but in some things I am a bit compulsive). I decided to give Erlang a try first because I understood it has much less of a steep in the education curve. So I went to the Erlang site, downloaded the compilee and started working on the User Guide.
Till now I have gone through only the initial chapters and problems on the site, but it has already given new perspectives. It has already given me new insights into the term ‘variable’. I got a new understanding on the word ‘assign’. The fact that an Erlang variable can only be bounded once and we can never change the value later was kind of a shock to me at first. I was baffled by the fact that a language would exist without a feature of reassignment. I asked around in IRC and that is when I got an insight on how variables are treated in Erlang. The ‘=’ operation is not strictky assignment operation. It is actually a ‘MATCH’ operator. If you write something like Left = Right. it is only checking if the left matches the right and returns a true or false. If it is seeing Left for the first time, and that is when assignment happens. And once it is assigned, it cannot change.
Another thing I was stunned was when I was going through lists. Var = [1, 2, 3]. returns [1, 2, 3]. But Var2 = [97, 98, 99]. returns the string “abc”. I again asked in IRC what if I wanted the list of numbers [97, 98, 99] and the answer was that that is exactly what I have got with me “abc”. A String is a list of their ASCII values. So to do something like
[97, 98, 99].each do { |i| i + 1 }
to return a list of [98, 99, 100] the code in Erlang will be like
[X + 1 || X <- "abc"]
I also find it amusing about the use of full stops instead of semicolons for ending the statement. Overall Erlang had been a new experience to it and I believe I have started to like it. After I finish the User Guide I will continue with Learn you some Erlang.
And I have found some decent blogs on Erlang which I will be visiting
Mitchell Hashimoto
Yariv Sadan
Jack Moffitt
Joe Armstrong
Priority for my NExt year is Java, so I am not sure how much I will be involved with Erlang. But I wish I could do some serious look into it.
Plans for 2012: To be a better programmer
After 5 years of a career in PHP web application development I will be moving to Java development from March of 2012. I have started brushing my Java gyan and learning more on the enterprise aspects of the language.
As the year is about to end, I thought it would be a good time to have a look back at my career and get a good perspective of my abilities and to plan for the future. I have seen the Comptetency matrix before and thought it will be a decent scale. I am hereby measuring myself on that scale and is setting a goal for the next year.
The current level is given and the expected value for 2012 end is given in the bracket. After each section the steps needed to be taken and the books to be read are given with further explanation on why some levels stay the same and why some change. The idea is not to read all the books in full. It is a continuous process and some books will take years to understand fully.
Computer Science
- Data structures : level 1 (level 2)
- Algorithms : level 1 (level 2)
- Systems Programming : level 1 (level 1)
I had studied these subjects in college, but to tell you the truth haven’t used most of the concepts after it. So my knowledge is shaky and I need to build on it. The importance is on learning data structures and algorithms and whether I will look into compilers will depend on my time, that is why it is still on level 1.
Books to study:
Software Engineering
- Source Code and Version Control : level 1 (level 2)
- Build Automation : level 0 (level 0)
- Automated testing : level 0 (level 1)
Me being a PHP developer most of my life never aided me in any sense in using automated tools or testing, that is is why I am still in level 0. Coming new to live Java development, I am not sure what is waiting for me. That is ehy there is no greater gain in this field. Regarding version control I have played with Git, mainly at github and is using SVN at work. But still I am just a passive user. need to learn more.
Books to study:
- Problem Decomposition : level 1 (level 2)
- System Decomposition : level 1 (level 2)
- Communication : level 2 (level 3)
- Code Organization (within file) : level 1 (level 2)
- Code organization (across project) : level 1 (level 2)
- Source Code Organization : level 1 (level 2)
- Code readability : level 2 (level 2)
- Defensive coding : level 0 (level 1)
- Error handling : level 0 (level 2)
- IDE : level 0 (level 2)
- API : level 0 (level 1)
- Frameworks : level 1 (level 2)
- Requirements : level 2 (level 3)
- Scripting : level 2 (level 2)
- Database : level 2 (level 3)
Programming Language
- Core Java Volume 1 & 2
- Effective Java
- Java Puzzlers
- Java Generics and Collection
- Java Concurrency in practice
- Head First Servlets and JSP
- Head First EJB
- Beginning JEE6 with Glassfish 3
- JavaScript: The Definitive Guide
- JavaScript: The Good Parts
- jQuery in Action
- Beginning Python: From Novice to Professional
- Learning SQL
- High Performance MySQL
- Learn Emacs (some how or the other)
- Languages with professional experience : level 1 (level 2)
- Platforms ” ” : level 1 (level 1)
- Years of experience : level 1 (level 2)
- Domain Knowledge : level 1 (level 2)
- Tool knowledge : level 1 (level 2)
- Languages exposed to : level 1 (level 2)
- Codebase knowledge : level 1 (level 2)
- Knowledge of upcoming technologies : level 1 (level 2)
- Platform internals : level 1 (level 2)
- Books : level 1 (level 2)
- Blogs : level 2 (level 3)