Who’s more popular, The Rani or Borusa?

July 20th, 2010  

This visualization of Doctor Who villains since 1963 will tell you:

Move over, U+20A8

July 20th, 2010  

India unveils a new symbol for the Rupee.

Dan Ariely on online dating

July 8th, 2010  

Interesting interview with the economist Dan Ariely on why online dating is so unsatisfying:

Online dating is becoming the poster child for a class of problems that software / the web is really, really bad at solving.

No clue about type design

July 8th, 2010  

Bruno Maag doesn’t pull his punches in this interview about Aktiv, his Helvetica-killer:

…Max Miedinger [Helvetica’s designer] didn’t have a clue about type design. He was the salesman at [foundry] Haas’sche Schriftgießerei for Christ’s sake.

Ouch.

Giant toy robots and donuts

July 3rd, 2010  

Eric Joyner paints retro-looking toy robots and donuts exclusively, like Too Many Choices II from 2008:

A day of MUNI

June 20th, 2010  

Red is less than 19 MPH.

Comic Sans brings it

June 15th, 2010  

What an arrogant bunch of vectors…. (Via httf)

And speaking of tinfoil hats…

June 13th, 2010  

Magnetically Induced Hallucinations Explain Ball Lightning, Say Physicists. And if UFOs are actually ball lightning, then does the X-Files ultimately owe its popularity to lightning storms?

Grasping the nuclear fourth rail of Python syntax with both hands and holding on for dear life

June 13th, 2010  

In Python vs. Ruby: A Battle to The Death, Gary Bernhardt wishes for Ruby-style blocks in Python.

The BDFL has already weighed in on anonymous blocks in Python:

If you want anonymous blocks, by all means use Ruby. Python has first-class callables, Ruby has anonymous blocks. Pick your favorite, but don’t whine that neither language has both. It ain’t gonna happen.

This seems to imply that first-class callables and anonymous blocks are mutually exclusive language features, but that’s wrong: JavaScript has the ability to pass callables around like anything else, and it has anonymous functions, which can be used just like Ruby’s anonymous blocks. Does that mean JavaScript is better than Python or Ruby? My feelings about Ruby are indifferent with a chance of rain, but I love Python, so I’ve got to ask: are you going to take this lying down, Python?

I’m not sure Python needs full-blown, Ruby-style anonymous blocks. But it might be good enough to be able to use function definitions as r-values, like JavaScript can. (If you’re not already wearing your tinfoil hat, now might be a good time to put it on.)

This would allow asynchronous code to be written in conceptual order (just like in JavaScript):

do_something_asynchronous(param1, param2, (def callback(result):
    do_something_with_result(result)
))

And it would allow encapsulation of lexical scope inside specific iterations of a loop to be used later when an asynchronous call returns (just like in JavaScript):

for item in results:
    (def single_iteration():
        do_something_asynchronous(param1, item, (def callback(result):
            do_something_with_result_and_item(item, result)
        ))
    )(item)

I’ve even had occasion to want that other Python namespace, class, to operate as an r-value:

class MyConverterClass(BaseConverterClass):
    my_converter_type = (class MyConverterType(float):
        def __str__(self): # a custom __str__ method
            return '%0.2f' % self
    )

In these examples I’ve wrapped their inline definitions in Python’s great syntactical equalizer, the parenthesis. It would be even nicer to be able to leave them off, but I’m sure that this syntax would run headlong into Python’s whitespace-based block definitions, and it would be even more of a train-wreck without parentheses.

I’ve also named the defs and classes. It would also be nice to be able to omit the function or class names if they were unneeded (just like in JavaScript). But anonymous functions, a.k.a. lambdas, are the electric third rail of Python syntax, so anonymous classes would be… I dunno, the nuclear fourth rail?

Fuchsia, baige [sic], puke, butter yellow, pistachio…

June 12th, 2010  

In a fascinating bit of amateur lexical analysis, Stephen Von Worley created this color strata image, using data collected from XKCD‘s Color Survey:

Sadly, pistachio, a hue that’s notoriously difficult to pin down, is nowhere to be found. Spencer Finch will be disappointed.

If anyone’s interested in the actual linguistics behind color names, Berlin & Kay’s Basic Color Terms (Amazon link) is the seminal work, although I’m pretty sure they didn’t discover color names like baige [sic], puke, or butter yellow.