Search the web
Sign In
New User? Sign Up
50g
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Hear how Yahoo! Groups has changed the lives of others. Take me there.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Can anyone answer a question about compiled local variables?   Message List  
Reply | Forward Message #902 of 981 |
RE: [50g] Can anyone answer a question about compiled local variables?

The left arrow on its own is a compiled local variable, and the X and Y are non-compiled local variables. Hence 3 values are required for your program to make the value assignments. You need two variables each with left arrow as the first character in the name.

 

Jeremy

 


From: 50g@yahoogroups.com [mailto:50g@yahoogroups.com] On Behalf Of rickwendel763242
Sent: 05 July 2009 21:11
To: 50g@yahoogroups.com
Subject: [50g] Can anyone answer a question about compiled local variables?

 




I made a program that looks like this: << Right Arrow (0 key) and a left arrow from the CHAR menu followed by X Y << X Y + >> >>.

1) No matter what the program is doing it drops 1 number in the stack above it.

2) If you only enter two numbers and their is no number above the two level stack, you get an error.

3) If you try to enter a number into the program before the point where the variables are initialized, all sorts of weird things happen and it won't let you.

4) You don't end up with any extra variables at the end of the program execution but then again I don't think its actually acting as a compiled local variable with the left arrow added. If you remove it and just use regular local variables theirs no problems.

5) So, can anybody write a simple program using compiled variables so I don't have to PURGE all the variables I use all the time?



Sun Jul 5, 2009 8:22 pm

leikkaus27
Offline Offline
Send Email Send Email

Forward
Message #902 of 981 |
Expand Messages Author Sort by Date

I made a program that looks like this: << Right Arrow (0 key) and a left arrow from the CHAR menu followed by X Y << X Y + >> >>. 1) No matter what the...
rickwendel763242
rickwendel76...
Offline Send Email
Jul 5, 2009
8:11 pm

The left arrow on its own is a compiled local variable, and the X and Y are non-compiled local variables. Hence 3 values are required for your program to make...
Jeremy Hawdon
leikkaus27
Offline Send Email
Jul 5, 2009
8:22 pm

So, how do your store data in variables from the stack and use it anywhere in the program or sub-routines? Where's the left arrow go?...
rickwendel763242
rickwendel76...
Offline Send Email
Jul 5, 2009
9:28 pm

The left arrow becomes part of the name of the variable, e.g. << -> <-X <-Y << <-X <-Y * >> >> This takes 2 numbers off the stack....
Don Hart
ddhart1
Offline Send Email
Jul 6, 2009
3:31 am

... I will write one using a single command. Type in 'PROG(X,Y)=X*Y^2' and then push DEF. PROG appears. Recall it an see that it looks like this. << -> X Y...
Tim Wessman
timwessman
Online Now Send Email
Jul 7, 2009
4:16 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help