Teen Programmers Unite  
 

 

Return to forum top

STACKS

Posted by SUDA [send private reply] at March 17, 2003, 07:58:18 PM

DO YOU HAVE AN EXAMPLE OF A PROGRAM WHERE IT USE STACKS TO ADD , MULTIPLY, SUBTRACT, DIVIDES?

Posted by ItinitI [send private reply] at March 17, 2003, 09:05:34 PM

Don't _YELL_
-OR-
get your keybord fixed. (^_^)

Posted by regretfuldaydreamer [send private reply] at March 18, 2003, 12:20:02 PM

NO, WE DON'T.

IN WHAT LANGUAGE ANYWAY?

Posted by RedX [send private reply] at March 18, 2003, 03:49:02 PM

One capital letter per sentence or name, is it really that hard to remember?

Posted by regretfuldaydreamer [send private reply] at March 18, 2003, 04:20:13 PM

OK, lets stop taking the piss and answer his question seriously, except I seriously have no real idea what he is on about (well, multiplication maybe, but I have never seen a stack used to add, subtract or divide.)

Posted by buzgub [send private reply] at March 18, 2003, 11:09:23 PM

I think he's talking about an rpn-style calculator, where as numbers are encountered they are pushed onto a stack, and as operators are encountered numbers are popped off the stack, the operation performed, and the result pushed back to the stack.

No, I don't have code for one.

You must be logged in to post messages and see which you have already read.

Log on
Username:
Password:
Save for later automatic logon

Register as a new user
 
Copyright TPU 2002. See the Credits and About TPU for more information.