Hello World

As a typical programmer perhaps, I have a habit of embarking in any new mission with a nice and sweet “hello world.” I intend to keep this site as a collection of my thoughts, ideas and as a notepad of my various curiosities and I keep collecting and refining them over time. As per the name, I believe it was a lucky coincidence that I decided to keep this site as a blog, you know, the name is just too good to give up on. My vanity didn’t permit me to just keep this domain parked once I got it :)

Apart from this. here’s the typical hello world. Since I’m doing Java at the moment, in Java it is:

public class HelloWorld{

public static void main(String[] argv){

System.out.println(”Hello World”);

}

}

Looks ugly.. Here’s a python version

print “Hello World”

To top it off, here’s what I’d do in assembly. Of course it’ll only run on a *nix box (syscalls) but whatever..

.text
.global _start

_start:
movl $len, %edx
movl $msg, %ecx
movl $1,%ebx
movl $4,%eax
int $0×80

movl $0,%ebx
movl $1,%eax
int $0×80

.data

msg:
.ascii “Hello World\n”
len = . – msg

This is probably enough of hello world for now. I can add some more but it’s just going to be redundant… :)

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google
  • Reddit
  • Slashdot
  • description
  • LinkedIn
  • Live
  • StumbleUpon
  • Technorati

Comments (1)

WorldOctober 25th, 2008 at 8:53 am

Did you call me! I was just bit busy to reply. I was preparing to welcome winter, anyway keep coding hacker.

Leave a comment

Your comment