Thursday, May 16, 2013

Learning Scheme

I am currently in the process of learning Lisp, more specifically the Scheme dialect of it. I was in doubt over whether to start with Scheme, Common Lisp or Clojure, but eventually I found a random internet comment essentially saying "rather than spending a lot of time figuring that out, you should just start". So I chose Scheme because I also have an ambition to read SICP at some point.

I have heard a lot of good things about the Lisp family and how it can change your perspective on programming if you're coming from an OO/procedural background. So far I haven't had the motivation to spend time on something that only seems tangentially relevant to numerical programming, but I find myself more willing to prioritize learning new programming-related stuff of whichever type presently.

As I'm writing this post, I am also researching whether what I'm writing is actually true. I was about to write that lazy evaluation was one of the ways in which Scheme could shine in some numerical applications (iterative schemes etc.). However, now I see that Scheme also does eager evaluation. So as of now, there is nothing that suggests to me that the Lisp family will be of use in a way that Fortran or C cannot do better, numerically speaking.

Wait a minute! Now I see that Scheme indeed supports lazy evaluation, just not as thoroughly as Haskell... much to learn here!

Learning Scheme definitely is making me think. At first I was mostly thinking "this is just a really illegible way of writing a program" but it's starting to grow on me. Now I am working on learning about continuations, which is a hard concept to grasp, and I don't fully understand its implications yet. Hopefully, soon I will, and it seems like this is one of those concepts that can be mind-expanding. For example, the yield statement in Python seems to be closely related to the continuation concept.

There will probably be more on this later. I thought this should be a 'useful' post with a 'quantity' tag.. but now reading through I cannot see how this post is useful for anyone but myself. Brain Sputter it is!

EDIT: This last comment prompted a post about the need for another label. Thus, the label for this shall be "Progress Report"!

No comments:

Post a Comment