Futurama   Planet Express Employee Lounge
The Futurama Message Board

Design and Support by Can't get enough Futurama
Help Search Futurama chat Login Register

PEEL - The Futurama Message Board    Re-Check/Weird Scenes    10 sin, 20 go to hell « previous next »
 Topic locked! 
Author Topic: 10 sin, 20 go to hell  (Read 12528 times)
Pages: [1] 2 Print
Mr. Mxyzptlk

Crustacean
*
« on: 07-02-2003 01:29 »

10 sin
20 go to hell

alright....i know it's something to do with programming in BASIC....but I still don't get the joke....i figure if anyone can help me out this is the place to come!
El Zilcho

Professor
*
« Reply #1 on: 07-02-2003 01:37 »
« Last Edit on: 07-02-2003 01:37 »

10 Sin: Tells program to run a "Sin" subroutine.
20 Goto Hell: Tells program to go to a "Hell" label.

BASIC code is typed like that. 10 is the first line, 20 is the second, and so on. The program performs line 10 first, then goes to line 20. another example is
10 Home
20 Sweet
30 Goto 10
which means that line 30 goes back to line 10, making the whole thing read "Home Sweet Home."

If none of that made sense, then 10 Sin: 20 Goto Hell means "If sin, Then Goto hell."

P.S. I love that username!
ShineFusion

Professor
*
« Reply #2 on: 07-02-2003 01:44 »

I never understood that joke either.
beck

Bending Unit
***
« Reply #3 on: 07-02-2003 01:50 »

El Zilcho
 
Quote
10 Home
20 Sweet
30 Goto 10
which means that line 30 goes back to line 10, making the whole thing read "Home Sweet Home."
Wouldnt that rather be an endless Home Sweet Home Sweet Home Sweet...  smile
El Zilcho

Professor
*
« Reply #4 on: 07-02-2003 01:55 »

Yeah... but at least this time I didn't screw up, the writers did.
Chriswell

Bending Unit
***
« Reply #5 on: 07-02-2003 01:55 »

It's funny only if you're familiar with Basica programming.

Notice in I, Roomate the sign:

10 HOME
20 SWEET HOME
30 GOTO 10

Of ocurse it's flawed with that it'll make HOME SWEET HOME an infinite loop. Would've made more sense if it went:

10 HOME
20 SWEET HOME
30 GOTO 10
40 END

-cs



"It's toe tappingly tragic."
El Zilcho

Professor
*
« Reply #6 on: 07-02-2003 01:58 »

It's not 20 SWEET HOME, just 20 SWEET. In any case, in yours the END comes after the GOTO, so wouldn't it just keep GOING TO?
JDHannan

Bending Unit
***
« Reply #7 on: 07-02-2003 03:17 »

yeah, u guys almost all suck
if you REALLY wanted it to work and have a loop you'd have to have something like
10 loop=0
20 Home
30 if loop = 1 then END
40 Sweet
50 loop = loop+1
60 goto 20
(that was really hard to write cuz its so stupid)
beck

Bending Unit
***
« Reply #8 on: 07-02-2003 04:10 »
« Last Edit on: 07-02-2003 04:10 »

JDH
 
Quote
that was really hard to write cuz its so stupid
Did you mean, that it was really hard to write in spite of the fact that it's so stupid? I think, it'd give a better idea of what kind of  person you are.  smile  big grin
chickuaua

Crustacean
*
« Reply #9 on: 07-02-2003 09:37 »

In Mother's day, there are also some programming language jokes..

A sign says:

REPEAT
{ LOVE MOM }
WHILE 1>0;

This is probably Pascal, because in C there is no repeat..while loop. This code would just make an infinite loop not doing anything, since { LOVE MOM } is a code comment.

Also, another sign says:

CHR$(77) => "MANY THINGS SHE GAVE ME"

Although this doesn't make sense in any programming language, CHR$(77) means (in BASIC) ASCII character number 77, 'M'

Jokes like this should all really just be funny and not logical  smile
And, yes, I'm a programmer  big grin

10 SIN
20 GOTO HELL

This isn't stupid, it's just funny  smile It's no conditional jump, so, from this code, you'd just sin and go to hell  smile

10 HOME
20 SWEET
30 GOTO 10

This really should make an infinite loop, just look at recursive names like "PHP: PHP Hypertext Preprocessor" and "GNU: GNU's Not Unix"

 big grin big grin B-)
Mr. Mxyzptlk

Crustacean
*
« Reply #10 on: 07-02-2003 14:02 »

I figured that was what it meant but everyone seems to think that joke was amazing.....guess you have to be a programmer.....that joke is nothing compared to Fry missing the button in the middle of the target in "A Big Piece Of Garbage"...."oops"
SQFreak

Professor
*
« Reply #11 on: 07-02-2003 14:56 »
« Last Edit on: 07-02-2003 14:56 »

REPEAT is probably Pascal, but if they had used do...while, that can be C(++).

The infinite loop is part of the joke. Only CompSci people would get it, and if you get it, it is really funny. Wasn't there an infinite loop joke in "I Dated a Robot"?

At a camp I went to, it's a tradition to make class T-shirts. The Artificial Intelligence class's t-shirt was:
 
Quote
How to make an infinite loop: see other side
on both sides of the shirt. If they'd had extras, I would have bought one.

The real reason that BASIC is written
 
Quote
10 STATEMENT ONE
20 STATEMENT TWO
30 STATEMENT THREE
(in increments of ten)
is so that a programmer can come back in later and add, say, a line 25 without having to redo all the numbers.
canned eggs

Space Pope
****
« Reply #12 on: 07-02-2003 15:28 »

 
Quote
Originally posted by chickuaua:
This really should make an infinite loop, just look at recursive names like "PHP: PHP Hypertext Preprocessor" and "GNU: GNU's Not Unix"

Some people I know in a computational linguistics course wrote a program to identify ellipsis called VIEWIC.  VIEWIC stands for: "VIEWIC Identifies Ellipsis When It Can."
I always thought that was real clever.
JDHannan

Bending Unit
***
« Reply #13 on: 07-02-2003 15:48 »

no i did not mean in spite of the fact that its so stupid.  Its hard to write that because its so stupid.  Any normal person would write
10 Home
20 Sweet
30 Home
END
Amorpheus

Delivery Boy
**
« Reply #14 on: 07-02-2003 16:17 »

But that wouldn't be funny, would it?  roll eyes

And yeah, there was a loop joke in I Dated A Robot: "Oh dear, she's stuck in an infinite loop and he's an idiot. Oh well, that's love for you..." One of my favorites.  big grin
El Zilcho

Professor
*
« Reply #15 on: 07-02-2003 17:54 »

 
Quote
Originally posted by chickuaua:
CHR$(77) => "MANY THINGS SHE GAVE ME"

Although this doesn't make sense in any programming language, CHR$(77) means (in BASIC) ASCII character number 77, 'M'

"M is for the many things she gave me..."
El Zilcho

Professor
*
« Reply #16 on: 07-02-2003 17:56 »
« Last Edit on: 07-02-2003 17:56 »

 
Quote
Originally posted by canned eggs:
 Some people I know in a computational linguistics course wrote a program to identify ellipsis called VIEWIC.  VIEWIC stands for: "VIEWIC Identifies Ellipsis When It Can."
I always thought that was real clever.

Sounds like a Dilbert joke. "What does TTP stand for?" "The TTP Project. "

EDIT: Dammit, sorry for the double post. I was gonna paste this one into my first one.
canned eggs

Space Pope
****
« Reply #17 on: 07-02-2003 19:40 »

VIEWIC is cool because "VIEWIC Identifies Ellipsis When It Can" contains ellipsis.  Also, it's antecedent-contained ellipsis, so it forms another infinite loop.
Sil

Professor
*
« Reply #18 on: 07-03-2003 10:40 »

If you look at the number of Bender and Fry's apartment door, I think it's something like 00100100 , but I can't remember off the top of my head.  In any case, and I don't know whether it's been said before, but in the ASCII, that number means $.

Well I thought it was funny.
JDHannan

Bending Unit
***
« Reply #19 on: 07-03-2003 12:36 »

Sil> I am a dead horse, stop beating me.
El Zilcho> THANK YOU.  i've been trying to figure that one out, its not lessthan/equalto its a pointer
M points to (or "is for" ) the many things she gave me!!!
YES!
PCC Fred

Space Pope
****
« Reply #20 on: 07-04-2003 05:28 »

 
Quote
Originally posted by Chriswell:
It's funny only if you're familiar with Basica programming.

Notice in I, Roomate the sign:

10 HOME
20 SWEET HOME
30 GOTO 10

Of ocurse it's flawed with that it'll make HOME SWEET HOME an infinite loop. Would've made more sense if it went:

10 HOME
20 SWEET HOME
30 GOTO 10
40 END

-cs


That wouldn't work either, because line 30 causes it to return to line 10, and the prgram never reaches line 40, and therefore never ends.

However the following program WILL work.

10 FOR N = 1 TO 2
20 PRINT "HOME"
30 IF N = 1 THEN PRINT "SWEET"
40 NEXT N
50 END

Now if you want to see a BASIC program with some chest hair on it, click on the following link:

 http://teral.netfirms.com/PEEL/fred/Ff12003.zip
Sil

Professor
*
« Reply #21 on: 07-04-2003 13:01 »

 
Quote
Originally posted by JDHannan:
Sil> I am a dead horse, stop beating me.

I didn't know it had been said already, or I wouldn't have posted it at all.
chickuaua

Crustacean
*
« Reply #22 on: 07-04-2003 15:21 »

Is it just me, or is BASIC a problem to you guys ? :P
Please don't make up any programs that would work, because that really doesn't make sense  since that stuff in futurama is meant to be a joke and not supposed to work! :P
SQFreak

Professor
*
« Reply #23 on: 07-04-2003 15:32 »

How about we do this in C++?

for (int i = 0;i <= 1;i++)
{
   cout << "HOME";
   if (i == 0)
   {
      cout << "SWEET";
   }
}

(I used the AP Subset - assume <iostream.h> is included.)
PCC Fred

Space Pope
****
« Reply #24 on: 07-04-2003 20:11 »

 
Quote
Originally posted by chickuaua:
Is it just me, or is BASIC a problem to you guys ? :P
Please don't make up any programs that would work, because that really doesn't make sense  since that stuff in futurama is meant to be a joke and not supposed to work! :P

Don't interrupt me when I'm showboating, dammit!
Tjoppen
Delivery Boy
**
« Reply #25 on: 07-04-2003 22:10 »

Code:
call sin
jmp hell

:>

~ One software - one function(avoid bloat at all cost) ~
Coder, Absynth Interactive
chickuaua

Crustacean
*
« Reply #26 on: 07-05-2003 10:34 »
« Last Edit on: 07-05-2003 10:34 »

for ( ;; ) { cout << "HOME\n" << "SWEET\n" }
  tongue  tongue
Tjoppen
Delivery Boy
**
« Reply #27 on: 07-05-2003 12:15 »

HOME and SWEET are subroutines. It doesn't print anything(unless the subs themselves do). In C/C++:
Code:
for(;;)
{
Home();
Sweet();
}

~ One software - one function(avoid bloat at all cost) ~
Coder, Absynth Interactive
chickuaua

Crustacean
*
« Reply #28 on: 07-05-2003 15:05 »

or better yet ...

void Home ( void ) {
  Sweet ();
}

void Sweet ( void ) {
  Home ();
}

 tongue tongue tongue
SQFreak

Professor
*
« Reply #29 on: 07-05-2003 15:55 »
« Last Edit on: 07-05-2003 15:55 »

Nice catch, Tjoppen.

chickuaua: Something has to call Home(). And why is there a "void" parameter? Is that just a stylistic choice, or is there a syntactical reason?
Yorokobi

Bending Unit
***
« Reply #30 on: 07-05-2003 16:33 »

10 DIM MSG$(3)
20 LET MSG$(1)="HOME"
30 LET MSG$(2)="SWEET"
40 LET MSG$(3)=MSG$(1)
50 FOR I=1 to 3
60 PRINT MSG$(I)
70 NEXT I
SQFreak

Professor
*
« Reply #31 on: 07-05-2003 17:07 »

...but that's not infinite...
I don't know enough BASIC to change it, but if you infinitize it, you should be able to mod I by 3 and  choose a message.
Tjoppen
Delivery Boy
**
« Reply #32 on: 07-05-2003 17:49 »

chickuaua: No compiler will accept that code(although I guess you knew that)  tongue

SQFreak: The void parameter is optional in the function prototype, however I would recommend not omitting them since it makes code oh so much more readable  smile

Also, here's the code for a 23 byte ASM program that prints the HOME SWEET inf. loop:
Code:
org 0x100
mov dx, string
mov ah, 09h
loop1: int 21h
jmp loop1

string db "HOME",13,10,"SWEET",13,10,"$"

What one could do with Yorokobi's program is this:
Code:
5 OPTION BASE 0
10 DIM MSG$(3)
20 LET MSG$(0)="HOME"
30 LET MSG$(1)="SWEET"
40 LET MSG$(2)=MSG$(0)
50 I = 0
60 PRINT MSG$(I)
70 I = (I + 1) MOD 3
80 GOTO 60

<Leela> Sigh.. I need coffee. </Leela>

~ One software - one function(avoid bloat at all cost) ~
Coder, Absynth Interactive
SQFreak

Professor
*
« Reply #33 on: 07-06-2003 00:22 »

Tjoppen: Sure a compiler will accept the code if you pre-declare the functions (write function prototypes before writing the functions, like you do in header files of classes.). BTW, AP Subset does not allow void parameters. Strange. I didn't know they existed.
chickuaua

Crustacean
*
« Reply #34 on: 07-06-2003 06:09 »

You guys are making this joke seem very very stupid, that is, the attempts to make something like that work are really   puke
Tjoppen
Delivery Boy
**
« Reply #35 on: 07-06-2003 09:03 »

Well, we cooked our shoes in the dryer and got bored...

~ One software - one function(avoid bloat at all cost) ~
Coder, Absynth Interactive
PCC Fred

Space Pope
****
« Reply #36 on: 07-06-2003 18:21 »

I think I can tighten up my earlier code:

10 FOR N=1 TO 2:PRINT "HOME":IF N=1 THEN PRINT "SWEET"
20 NEXT N: END
SQFreak

Professor
*
« Reply #37 on: 07-06-2003 18:40 »

But it's still not infinite and the other one was much more readable. I prefer to sacrifice number of lines (and source code size) for readability.
Tjoppen's is my favorite (the infinite BASIC program).
Bones

Bending Unit
***
« Reply #38 on: 07-07-2003 18:07 »

my head hurts
Yorokobi

Bending Unit
***
« Reply #39 on: 07-07-2003 18:33 »

Well, obviosly the

10 HOME
20 SWEET
30 GOTO 10

is a simplification, so you can read it, get the joke, and continue watching the episode.

It's still interesting to dig up this truely moldy knowledge (for me anyway) and have a go at what it should say.

As with all programming languages, we see the prefernces of the programmer in the various code examples that have been offered.

And as will all programming lanugages there are about as many ways to approach it as there are people offering opinions.

Heck we could go nuts and read hex code that corrisponds to the ASCII codes of each of the characters, and read that out of a seperate data file....  and so on...
Pages: [1] 2 Print 
 Topic locked! 
« previous next »
Jump to:  

Powered by SMF | SMF © 2006, Simple Machines | some icons from famfamfam
Legal Notice & Disclaimer: "Futurama" TM and copyright FOX, its related entities and the Curiosity Company. All rights reserved. Any reproduction, duplication or distribution of these materials in any form is expressly prohibited. As a fan site, this Futurama forum, its operators, and any content on the site relating to "Futurama" are not explicitely authorized by Fox or the Curiosity Company.
Page created in 0.145 seconds with 17 queries.