http://qs321.pair.com?node_id=813859


in reply to Re^2: The Oldest Plays the Piano
in thread The Oldest Plays the Piano

See also Explain one liner for fibonacci.

Update: Explain Fibonacci one-liner ?? too.

Update 2010-07-21: Try this for Catalan numbers:

perl -le'$==0,(1x$_)=~/(^)(|1(?2)(?2)(?(?{})))$(?{$=++})^/,print$=for +0..13'

Update 2010-11-21: A nicer version for the Catalan numbers:

perl -le'$==0,(1x$_)=~/^(|()1(?1)(?1)\2)$(?{$=++})^/,print$=for 0..13'