Thoughts

Punk Rock Languages

A Polemic - by Chris Adamson

17 minute read

It’s rare that in one article the author praises C and JavaScript at the same time. After I read this one, I fear that it may vanish any time soon, so I decided to repost it here. That C has won the end-user practicality battle is obvious to everyone except developers. The year is 1978, and the first wave of punk rock is reaching its nihilistic peak with infamous U.

You Think You Know If Else?

The subtlety of if else statement

2 minute read

I was shocked during this fantastic video by Kevlin Henney not because all the programming history that he talked about, but by one simple example of if-else statement. Here is the leap year function he gave as an example in the talk: def isLeapYear(year) { if (year % 400 == 0) return true if (year % 100 == 0) return false if (year % 4 == 0) return true return false } def isLeapYear(year) { if (year % 400 == 0) return true else if (year % 100 == 0) return false else if (year % 4 == 0) return true else return false } Which one do you think is better?

2 minute read

Some time ago I read this article about Why Mit Stopped Teaching SICP. Gerry Sussman said that nowadays people do not often need to build something from scratch again, there exists massive and huge library code for nearly everything. So today’s programming work is more like poking around other people’s code until it works. I’ve beening doing Android dev for some time now, and I have to say that I sadly agree with him.

2 minute read

There is this stereotype impression about technology industry, that it is a cruel game only for energetic and ambitious young men, when you get old, you will be kicked out mercilessly. This doesn’t bother me so much since I was still young a few years ago, but since now I am getting older it starts to act as a background noise that grabbed me more and more attention. Is this the truth?

2 minute read

最近因为工作的原因在学clojure,其实我一直都想学一个LISP语言,现在终于有人付钱让我学啦,呵呵。 最早接触到LISP是因为Emacs。当年在研究生时给大学的自然语言研究组帮忙的时候,教授就是Emacs的资深(20年+)用户,我也就开始一点一点的接触了,后来经过一段时间的压迫性的苦练,终于入门了。有一天无意中发现了Emacs Lisp Intro,就开始学习emacs lisp,可惜半途而废了。 因为clojure还比较新,所以没有什么太多资料。我就买了一些关于LISP的经典书籍,比如这个 《Structure and Interpretation of Computer Programs》。但由于本人的拖延症的病情,所以打算从今天开始读第一章了(第二遍尝试)。。。 在开篇有一段引言如下: ``I think that it’s extraordinarily important that we in computer science keep fun in computing. When it started out, it was an awful lot of fun. Of course, the paying customers got shafted every now and then, and after a while we began to take their complaints seriously. We began to feel as if we really were responsible for the successful, error-free perfect use of these machines.