As some of you already know by now, I have nominated myself for the 2010 Australian Federal Election as a candidate for the Commonwealth Electoral Division of Sydney, endorsed by the Secular Party of Australia. It is both an honour and a privilege simply to be able to stand for such office. It is truly a remarkable thing to participate in a society that conducts its affairs in this manner.
I’ve been writing a lot of UI code lately, and one of the bread-and-butter operations in UI code is toggling boolean state, usually in response to a button press. Now, what does toggling code look like?
I present to you a youthful and somewhat insensitive re-telling of a classic fairy tale.
Please note—The following story is not meant to imply that the residents of Chernobyl were:
- tax evaders; or
- incompetent home builders; or
- mean spirited; or
- comparable to swine; or
- given to formulaic naming of their children.
Any resemblance to any person, living or dead, is purely (and tragically) coincidental.
… but this ain’t one.
Today Yahuda Katz posted his 10 favourite things about the ruby language. His list certainly reflects most of the things I find very appealing about the language. The sixth item highlights Ruby’s excellent support for blocks and lambdas and an argument is mounted that when performing file operations in languages without them, programmers are
forced to use an inline “ensure” block every in the same lexical scope that they originally opened the file in, to ensure that the resource is closed. As is often the case the comparison is made to Java, but as any seasoned Java developer will tell you (and this point has probably be made many, many times) it just isn’t true. Java supports a safer and comparable idiom via the anonymous inner class.