Archive for November, 2009
This was first published in April 2006. Spring was a novelty. Even more so in a British life assurance company – that’s not your West Coast start-up. So please take it in context. I only re-post this, because it was the most linked to page on my old blog (with both positive and negative comments). [...]
Filed under: Uncategorized | Leave a Comment
Wayback Machine
I was delighted to find my old blog neatly folded and archived on the marvelous Wayback Machine. I spent hours trying to convert it to WordPress and eventually gave up and just dumped it, blogging some lofty nonsense about detachment. It turns out the Wayback Machine’s got it all – you can just get it [...]
Filed under: Uncategorized | Leave a Comment
Swapping classes
I’ve been thinking about this the way Log4J, commons logging, SLF4J, Logback and the related libs blatantly swap classes with the same qualified names. Like, you take this jar out, put the other jar in and you’ve got a different implementation. One example is the StaticLoggerBinder – the interface is defined in the API.
Filed under: Uncategorized | Leave a Comment
Quick sort in Scala
def qsort(list:List[Int]):List[Int] =
{
list match {
case x::xs => qsort(xs filter(_<x) ) ::: x :: qsort(xs filter(_>x))
case Nil => Nil
}
}
print(qsort(List(4,6,5,0,2,3,1,7,8,9)))
Short and sweet!…
Filed under: Uncategorized | Leave a Comment