Post Reply 
No way to get an element free of brackets
02-17-2021, 10:48 AM (This post was last modified: 02-17-2021 10:56 AM by Didier Lachieze.)
Post: #5
RE: No way to get an element free of brackets
Here is a simplified way to use lists to assign values to global variables, not requiring CAS:

Code:
EXPORT myv1, myv2, myv3;

EXPORT LSTOR(l1,l2)
BEGIN
 EXPR(l2+":="+l1);
END;

EXPORT TST()
BEGIN
 LOCAL lstv;
 lstv:={"myv1", "myv2", "myv3"};
 LSTOR({1,2,3},lstv);
 PRINT(myv1+" "+myv2+" "+myv3);
 LSTOR({4,5,6},lstv);
 PRINT(myv1+" "+myv2+" "+myv3);
END;
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: No way to get an element free of brackets - Didier Lachieze - 02-17-2021 10:48 AM



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