Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

You are awesome. That's seriously the easiest bit of technical reading I've ever done. I tip my hat to you!


Speaking of awesome, check out other stuff Fred Hebert wrote.

Learn You Some Erlang For Great Good: http://learnyousomeerlang.com/

His blog posts are great too: http://ferd.ca/

And his new (free) book, Erlang In Anger: http://www.erlang-in-anger.com/


Yes, easy reading, as a non-programmer the only thing that lost me was the throw away line in the code comments on "function arguments are call-by-value". I've some recollection that call-by-value and call-by-reference are options here but not entirely clear what the meaning of "call-by-value" is.

It probably doesn't matter though - the Wikipedia reference is ever-so slightly to terse for me to understand the implications thoroughly too, http://en.wikipedia.org/wiki/Evaluation_strategy#Call_by_val....

Am I right in saying that if I call a function on $2, say, that unless that variable is explicitly assigned in the function that $2 remains unchanged after the function operates. But that with a call-by-reference the value of the variable itself will be altered? Something along those lines.


Am I right in saying that if I call a function on $2, say, that unless that variable is explicitly assigned in the function that $2 remains unchanged after the function operates. But that with a call-by-reference the value of the variable itself will be altered?

You've got it. At least that's what passing a variable by reference vs. by value means in other languages, such as PHP.


Now do one on sed! :D




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: