Nothing compares to you...

Posted Thursday, August 26, 2004 1:19 AM by CumpsD
It's a great song, forgot who's the artist, but here is a piece of code that came forward when hearing this song:

C#:

int you = new int(), nothing = new int();

if (nothing.CompareTo(you) == 0) {

   Console.WriteLine("Nothing Compares To You!");

}

Shorter:

int you = new int(), nothing = new int();

Console.WriteLine(nothing.CompareTo(you) == 0 ? "Nothing Compares To You!":"");


PS: It compiles.

And something from a friend of mine during a class of PL/SQL:

PL/SQL:
declare
   Result number(2);
   heart_broken exception;
   gun_trigger exception;
begin
   if SHOW_LOV('myLov') = false then
      go_block('Heart_broken');
   else
      go_block('Joy');
   end if;
   exception
      when heart_broken then
         raise gun_trigger;
end;

(I believe it compiles as well ;))

Update: It seems it's from Sinead O'Connor.

Filed under: ,

Comments

# re: Nothing compares to you...

Wednesday, August 25, 2004 7:28 PM by Jochen

Cool, but I still, can't understand the language you coded it in... But I find the matches with the song ;)

# re: Nothing compares to you...

Thursday, August 26, 2004 9:52 AM by Russ C.

It was 'Prince' first of all, Sinead O'Conner did a cover of it.

# re: Nothing compares to you...

Thursday, August 26, 2004 12:32 PM by David Cumps

Sorry :) I didn't knew it from the start, someone told me on ICQ.

# re: Nothing compares to you...

Friday, August 27, 2004 10:56 PM by BertG

Sinead O'Conner version is GOOOD!
and now I'll think of this code, instaid of enjoying the song :s :p