HP Forums

Full Version: Variable e not usable for local-variable
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
The program mentioned in the other thread needed some local variables, as I am lazy I usually take short names and came up with e, as it should hold the result of euler(n), the editor refused to take it. So I used the cas to find out that e cannot be taken as a variable at all although I think to have read that all small letters are available. That is not very serious but can be changed if the system used another symbol, perhaps a fat printed e, for 2.718..., just like it does with i.
Maybe more meaningful error messages, especially in cas-programs where no debugger is available would be helpful, too. Errors like this take more time to find than writing the whole program.
Arno
(09-01-2015 10:01 PM)Arno K Wrote: [ -> ]The program mentioned in the other thread needed some local variables, as I am lazy I usually take short names and came up with e, as it should hold the result of euler(n), the editor refused to take it. So I used the cas to find out that e cannot be taken as a variable at all although I think to have read that all small letters are available.

Neither e nor i can be used as variables in Home or in CAS.

(09-01-2015 10:01 PM)Arno K Wrote: [ -> ]That is not very serious but can be changed if the system used another symbol, perhaps a fat printed e, for 2.718..., just like it does with i.

Even though i is often displayed as a stylized i, it can be keyed in by the user as a plain i, so i must still remain a reserved PPL word. So even if they started calling e "e", it wouldn't stop e from being a reserved PPL word.
(09-02-2015 03:22 AM)Joe Horn Wrote: [ -> ]
(09-01-2015 10:01 PM)Arno K Wrote: [ -> ]The program mentioned in the other thread needed some local variables, as I am lazy I usually take short names and came up with e, as it should hold the result of euler(n), the editor refused to take it. So I used the cas to find out that e cannot be taken as a variable at all although I think to have read that all small letters are available.

Neither e nor i can be used as variables in Home or in CAS.

(09-01-2015 10:01 PM)Arno K Wrote: [ -> ]That is not very serious but can be changed if the system used another symbol, perhaps a fat printed e, for 2.718..., just like it does with i.

Even though i is often displayed as a stylized i, it can be keyed in by the user as a plain i, so i must still remain a reserved PPL word. So even if they started calling e "e", it wouldn't stop e from being a reserved PPL word.

Well, that is correct and perhaps ok, but contrary to e i can be used as a local variable and this is what I am interested in.
Arno
Reference URL's