New's Software for HP Prime does not allow Cesar program to run
|
03-30-2020, 04:45 AM
Post: #1
|
|||
|
|||
New's Software for HP Prime does not allow Cesar program to run
Hello,
I used cesar program in HP own sight paper EXPORT CESAR() BEGIN local n; LOCAL S,M,K; ””M; //The user is asked to enter the encrypted word INPUT(n,”Insert in quotation marks”,”Encrypted word”); SIZE(n)S; FOR K FROM 1 TO S DO //This time we shift by 3 letters backwards M+CHAR(ASC(MID(n,K,1))-3)M; END; PRINT(M); END; It worked in last OS but in the new one I get error at ""M; Can anyone tell me why it works in old OS and not in the new OS? |
|||
03-30-2020, 06:38 AM
Post: #2
|
|||
|
|||
RE: New's Software for HP Prime does not allow Cesar program to run
(03-30-2020 04:45 AM)tom234 Wrote: Hello, Bonjour je pense qu'il manque un sto entre "" et M ainsi qu'à la ligne : Code:
Code: M+CHAR(ASC(MID(n,K,1))-3) sto M; Code:
Code: LOCAL M:="",......; Hello I think there's a sto missing between "" and M as well as the line: Code:
Code: M+CHAR(ASC(MID(n,K,1))-3) sto M; Code:
For the declaration you can write : Code: LOCAL M:="",....; Sorry for my english |
|||
03-30-2020, 01:06 PM
Post: #3
|
|||
|
|||
RE: New's Software for HP Prime does not allow Cesar program to run
(03-30-2020 06:38 AM)Tyann Wrote:(03-30-2020 04:45 AM)tom234 Wrote: Hello, ///// Did you run that code it doesn't work for me? The old OS software knows and can run it but not the new one. New OS has its new syntax problems. |
|||
03-30-2020, 01:44 PM
Post: #4
|
|||
|
|||
RE: New's Software for HP Prime does not allow Cesar program to run
There seems to be something wrong with your INPUT statement. I retyped the whole line and made the changes mentioned by Tyann and this runs:
PHP Code: EXPORT CESER() -road |
|||
03-30-2020, 04:20 PM
Post: #5
|
|||
|
|||
RE: New's Software for HP Prime does not allow Cesar program to run | |||
03-30-2020, 08:19 PM
Post: #6
|
|||
|
|||
RE: New's Software for HP Prime does not allow Cesar program to run
(03-30-2020 04:20 PM)tom234 Wrote: http://www.hp-prime.de/files/composite_f...ages_m.pdf That document is nearly 6 years old. The Prime f/w has been updated many times since then, and though I am not certain about this detail, it's likely there was a small adjustment to the allowed syntax and the original version used in that line has been improved, as seen in the slightly adjusted version posted by roadrunner. --Bob Prosperi |
|||
03-31-2020, 05:56 AM
(This post was last modified: 03-31-2020 05:59 AM by Tim Wessman.)
Post: #7
|
|||
|
|||
RE: New's Software for HP Prime does not allow Cesar program to run
Most likely syntax that was never supposed to work was made more strict in the checking that came later to avoid problems. Honestly, very little changed from before that was not "broken" in some way. Most of the issues deal with trying to use new features on older units, not the other way around.
The other possibility I see is that the author of the document DID NOT use the correct forward STO arrow character. So if you copied/pasted then the incorrect character was used in the PDF and then sent to the calculator. Hence the lines with STO complaining about issues... TW Although I work for HP, the views and opinions I post here are my own. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)