July 5, 2006

The Evolution of a Programmer (2)

Posted in Unknown at 12:45 pm by miharuyouth

Apprentice Hacker

#!/usr/local/bin/perl
  $msg="Hello, world.\n";
  if ($#ARGV >= 0) {
    while(defined($arg=shift(@ARGV))) {
      $outfilename = $arg;
      open(FILE, ">" . $outfilename) || die "Can't write $arg: $!\n"; 
      print (FILE $msg);
      close(FILE) || die "Can't close $arg: $!\n";
    }
  } else {
    print ($msg);
  }
  1;

Experienced Hacker

#include <stdio.h>
  #define S "Hello, World\n"
  main(){exit(printf(S) == strlen(S) ? 0 : 1);}

Seasoned Hacker

% cc -o a.out ~/src/misc/hw/hw.c
  % a.out

Guru Hacker

  

\n\n\n

New Manager

\n\n

10 PRINT "HELLO WORLD"
  20 END

\n\n\n

Middle Manager

\n\n

mail -s "Hello, world." bob@b12
  Bob, could you please write me a program that prints "Hello, world."?
  I need it by tomorrow.
  ^D

\n\n\n

Senior Manager

\n\n

% zmail jim
  I need a "Hello, world." program by this afternoon.

\n\n\n

Chief Executive

\n\n

% letter
  letter: Command not found.
  % mail
  To: ^X ^F ^C
  % help mail
  help: Command not found.
  % damn!
  !: Event unrecognized
  % logout

",1] ); D(["mb","

\n\n\n \n\n

\n
--
--h a y a t i   z a k a r i a @ a r i f f i n--\n\n

",0] ); D(["ce"]); //--> % echo "Hello, world."

New Manager

10 PRINT "HELLO WORLD"
  20 END

Middle Manager

mail -s "Hello, world." bob@b12
  Bob, could you please write me a program that prints "Hello, world."?
  I need it by tomorrow.
  ^D

Senior Manager

% zmail jim
  I need a "Hello, world." program by this afternoon.

Chief Executive

% letter
  letter: Command not found.
  % mail
  To: ^X ^F ^C
  % help mail
  help: Command not found.
  % damn!
  !: Event unrecognized
  % logout

  ps: cant remember where i got this from..this is great..even the same output can be generated by different coding… i wish that i could do the same..these people must be  very tough..

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: