Thursday, October 23, 2008

5 reasons luke skywalker is a complete idiot

Topless Robot gives solid evidence about the stupidity of Luke Skywalker. This stuff rocks!

Tuesday, October 21, 2008

varargs in java 5

I'm going to talk about one of the minor enhancements of Java 5; Varargs. Normally, if you are going to pass an arbitrary number of elements (object or primitive type) to a function, you would put them into an array and then pass the array to the function.
Assuming we have a concat() function such as

String concat(String[] tokens){
String result = "";
for(int i=0; i<tokens.length; i++){
result += tokens[i];
return result;

We will put all the Strings to be concatanated in an array and pass them to concat(). i.e. concat( new String[]{"come", "on", "eileen"} ) .

With Varargs, it is now possible to skip the array creation and pass the elements (again, object or primitive type) directly to the method. You change the concat() function so that it can accept them. String concat(String[] tokens){ becomes String concat(String... tokens){ and now you're free to pass any number of elements to concat() function without worrying about an array.
i.e. concat("come", "on", "eileen"); concat("dexymidnightrunners");

hugo gernsback

I was reading "Ultimate World" by Hugo Gernsback. After a little googling, I learnt that Hugo Award -which was my stepping stone for sci-fi literature ~10 years before- is named after Mr. Gernsback. If you need sci-fi reading recommandations, then take a look at Hugo Award and of course Nebula Award. My favorite novels from these awards are:

  • Dune and Children of Dune by Frank Herbert
  • The Forever War by Joe Haldeman
  • Neuromancer by William Gibson
  • Fahrenheit 451 by Ray Bradbury

Monday, October 20, 2008

video lectures

Here you can find an awesome video lecture site that's mainly focused on computer science. Every lecture video here has a powerpoint presentation screen next to it and that works great. Highly recommended!

linus torvalds' blog

Linus Torvalds begin recently to blog. Check it here.

top ten worst video game movies

james remar as raidenIf you want to know Gametrailers' list for top ten worst video game movies, take a look here (I think Doom is not bad enough for this list). As you'll see, Uwe Boll is the true king of crappy video game movies. Check his ratings @ imdb. No movie of his with a rating more than 5 over 10.