linguistics, computers, and puns
TopQueue in Scala - Part 1

I was once given the following interview question:

Design and implement a method to select the largest m values from a very large list of n numbers.

I liked this question because solving it (the way we'll be doing) touches on a good cross section of software design in Scala:

  • complexity ("Big O") analysis
  • polymorphism (subclassing, traits, and bounds)
  • testing!
  • ...and a few Scala-flavored ideas:
    • companion objects
    • implicit values

In this post we'll examine the problem, calling out a few factors that make this question interesting, and propose a design for our solution.

In upcoming posts, we'll follow the design through implementation, functional testing, and add a few bells and whistles. ...more

July 01, 2018 #Algorithms #Data Structures #Deep Dive #Interviews #Scala #TopQueue
JVM Upgrade for SmartOS

Joyent's SmartOS is a great virtual hosting platform. I've used it to deploy Ruby on Rails apps and even a Yesod app with excellent performance and minimal fuss. If you haven't already, go check it out. I deployed a full Tomcat Java app server in less than 30 minutes, including download and configuration time.

The Tomcat 7.0 package that SmartOS has is great, but the JDK 6 is showing some wrinkles. Given my fully configured and running system, how simple is it to install an aftermarket JDK 7 and configure Tomcat to use it?

Pretty damn simple. ...more

February 03, 2013 #JVM #Unix
Dead Tree Nostalgia

So I was digging through some old computer books the other day and found what you might call my first "serious" programming book [picture right]. (My first was this colorful gem.)

The Tandy 1000 Programmer's Reference Manual has has seen better days, but it's in pretty good shape for a 27-year-old book. But I own plenty of books published pre-1990. What makes this one special? Aside from it being among my first geek tomes, it also represents so much of what has changed about technology. ...more

September 10, 2012 #Assembly #BASIC #Books #RPN