Wednesday, September 19, 2007

politics - student gets tazered at john kerry talk

if you haven't seen it: http://www.youtube.com/watch?v=iqAVvlyVbag

think about it for a bit and let it settle in. what does this mean for our country?

i don't think there's anything conspiratorial going on here. i don't think kerry's people removed him cuz of the probing questions - the security guards were doing their job cuz he was breaking the rules of the event.

however, i do have a problem with the rules. the first amendment guarantees that the government will never suppress free speech, but it seems like we americans do a fine job suppressing ourselves anyway. don't say anything controversial at work, cuz you may get fired! or in this case, don't try to make a lengthy point at the mic cuz you may get forcefully removed! this isn't about the first amendment and law - it's about free speech in our culture (as reflected by the rules of such events) - or there lack of.

on the BBC, there was one event where tony blair and a member of the audience were literally shouting at each other. was that against their rules? hell no - it was damn good television!

american political culture is tragically restrained. this has the de facto effect of suppressing free speech and making politics generally dull and boring, motivating the population to censor itself. perfectly constitutional, but pathetically unhealthy.

Friday, September 14, 2007

life in ithaca so far

i've been here for over a month now, so here's the 411 so far

pros:
- ithaca's natural beauty goes pretty well with its hot and humid summer weather. nothing like cliff diving in to one of ithaca's many gorges!
- cornell's student theater is awesome - cheap, and great selection of indie movies
- lotsa stuff to do on campus. i plan on doing hockey and swing dancing on a regular basis
- my office mates - all girls - are a pretty entertaining group to work around
- academically, i'm learning a ton
- my room is HUGE

cons:
- summer's over soon, so i expect it'll get balls-clinking cold in a month or two
- i've started on a research project, which is great, but i'm expected to produce results by january. this means that unless i finish early (read: work my ass off), my winter break will be compromised...
- disappointingly, very few of the first year PhDs are enthusiastic drinkers ('alcoholic' is such a strong word...)

so all in all, things are going well and i'm diggin it over here!

Thursday, September 13, 2007

tech culture - computers as tools

computers are pretty amazing tools, but they're still just tools. yet, there's a certain mystique about them in our culture. for example, people often say, "it would be very slow for a human to calculate this, but a computer could do it almost instantly!" contrast this with how people talk about, say, hammers: "it would be very painful and slow for a human to knock this nail in, but with a hammer one could do it almost instantly!" the difference being the "with a hammer" as opposed to just the hammer by itself.

perhaps this kind of thinking promotes laziness amongst computer users. culturally, we expect computers to be autonomous, thus we don't bother learning the tools in much depth (how often do you read, much less write, software documentation?). yet if you just got a new power saw, you'd spend a few days learning the thing and reading the manual. maybe we need computers and software that could potentially cut off a limb or two if you don't use it properly. in the long run, maybe that'd save us tons of frustration and head ache?

software idea - facebook 'bets' app

how bout a facebook app that keeps track of bets between you and your friends? imagine logging in and seeing in the newsfeed, "Bob lost a bet to Jim! Now Bob has to come to class in his boxers!" or like, "Your friend Johnson has proposed a bet..."

software engineering - maintainable global variables using stacks

problem: global variables (and static singletons) are convenient for stuff that all functions/classes probably need to access (loggers, database connections, profilers). it's painful to pass all these around as arguments. but, it can also be painful if you want to temporarily change those variables (for example, if you want to temporarily log to a different file for a certain function call).

solution: for each global variable, make a stack. so instead of declaring "int x;" declare "stack x;". when you use it, just use the top element. when you need to change it temporarily, push on a new value, and pop it after you're done.

idea from: OpenGL does exactly this, as the whole library is just global state (you NEVER pass around any GL objects). you push/pop matrices, attribute sets, etc. it works quite well and looks very clean . LISP also does this when you use 'let' and bind to a global variable. it'll push your new value, and actually pop it out for you when the 'let' expression is done (ergo, lisp is awesome).