Post Reply 
Change the way LOCAL variable declaration works.
06-10-2014, 06:01 AM
Post: #4
RE: Change the way LOCAL variable declaration works.
Hello,

Quote: [Kind of]What I am trying to do is take 'names' as input, declare local variables programatical based on these names, and then use the variables

Is that accurate?
If yes, then, sorry, but I can not think of any easy way to do it... As a mater of fact, very few comuter languages have such abilities!

One thing that pops in mind (might not work, but worth a try):

Get the list of variables that you are interested in.
Create a list with n elements (as many as you have variables).
Then REPLACE, in your original expression each of the variables names with 'list(n)' where n is the index in the list of the variable that you are replacing... and then it should work...

Now, please note that if you are mixing numerical and CAS stuff together, it will probably not work as numerica/CAS inverwork on variables is limited.

But this technique should work if you stay purely CAS or purely non CAS.
Take care of properly quoting the arguements that needs it.

Cyrille
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Change the way LOCAL variable declaration works. - cyrille de brébisson - 06-10-2014 06:01 AM



User(s) browsing this thread: 1 Guest(s)