Monthly ArchiveJanuary 2008
Humor & Programming Languages & Science & Software 16 Jan 2008 05:22 pm
Problems Worthy of Attack
I found a great quote in the comments of Diomidis Spinellis’ blog entry Rational Metaprogramming:’Problems worthy of attack prove their worth by fighting back’ — Piet Hein
That’s a great way to put it!
Programming Languages & Software 16 Jan 2008 05:19 am
Vis a tergo: Baseball cards as objects
Rob’s discussing object models for baseball cards. He is evolving a design bit-by-bit.
My first question is what use cases do you want for your database of baseball cards? Searching real stats for the season? Or just searching for cards? To me, that changes the way I’d lay it out.
To play along, here is a primitive set of plain old Ruby objects to model what he has so far. I thought it might be interesting to contrast the two.
OK, well, I lied, it is a little different, because I went ahead and subclassed for the variant card type.
class Card
attr_reader :year, :number
def initialize(number, year)
@number = number
@year = year
end
end
class PlayerCard < Card
attr_reader :player
def initialize(number, year, player)
super(number, year)
@player = player
end
end
class BattingLeadersCard < Card
attr_reader :top_50_batting_players # this is a list of players
def initialize(number, year, top_50_batting_players)
super(number, year)
@top_50_batting_players = top_50_batting_players
end
def top_3
top_50_batting_players[0..2]
end
end
class Player
attr_reader :name, :team
def initialize(name, team)
@name = name
@team = team
end
end
Miscellaneous & Philosophy 13 Jan 2008 10:26 pm
Fwd: How to Enjoy a Convention [Phil Agre]
Fwd: How to Enjoy a Convention [Phil Agre]: “Think about this sociologically. You have a gathering of several
thousand people from one profession. Most of them work in middle of
nowhere places with two colleagues, one of whom they loathe. They spend
all year teaching the writings of other people (some of whom are their
heroes) to 19 year olds. Some of those heroes are walking around the
hotel. Of course they’re looking at the name tags.”
(Via Conference Presentation judo.)
History & Language & Philosophy & Politics & Programming Languages & Science & Software 02 Jan 2008 08:23 pm
Reading List that Inspired Smalltalk
Squeakland has a list put together by Alan Kay for his students that gives background on the ideas behind Smalltalk.
It looks like quite an interesting list.
