HP Forums
userRPL MAP command observations - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: General Forum (/forum-4.html)
+--- Thread: userRPL MAP command observations (/thread-19654.html)

userRPL MAP command observations - pier4r - 03-13-2023 10:49 AM

I used the MAP command very rarely, and I forgot it wanted to change flags, although the 50g advanced user guide v2 manual doesn't tell anything about flags to be set (normally there is a remark about flags).

While searching the web in the hope that someone talked about it, I found this somewhat interesting conversation from 2002: https://groups.google.com/g/comp.sys.hp48/c/84oio2JknbQ (that went off topic after a bit).

RE: userRPL MAP command observations - John Keith - 03-13-2023 07:05 PM

I did not know that MAP affected flags. Which ones?

MAP is also slow, even compared to DOLIST which isn't very fast. Here is a fast replacement for MAP using ListExt commands. It works for matrices or vectors but not for lists. It does not change the type of the array. The function can be a program, a list or a null-tagged object.


\<< SWAP OBJ\-> DUP \-> s

RE: userRPL MAP command observations - pier4r - 03-13-2023 08:59 PM

Thanks John for sharing, I'll put it in the collection of code snippets (see wiki4hp). I am not entirely sure which flags it wanted to change, as when I used it today in a program there was a popup asking me flags changes and I clicked cancel. Then I remembered that in the past I used the procedure store the flags, change what map wanted, and then recall the flags again.

For reference, the program was like


InputList @ a list of reals if I am not wrong
   IF @yes, IFTE would work too
      maxValue >

update: added the code here http://www.wiki4hp.com/doku.php?id=rpl:start under JKMAP