Post Reply 
Free42 question - SIGN
09-10-2021, 11:38 AM
Post: #2
RE: Free42 question - SIGN
On the HP-41C, SIGN was used to detect strings: it returns 0 for strings (and 1 for 0, unlike SIGN in BASIC, which returns 0 for 0).
On the HP-42S, there are specific functions for detecting types: REAL?, CPX?, MAT?, and STR?... and in that spirit, I added LIST? as well.

As for making all built-in functions work on lists in an element-wise fashion... Hmm, yes, that is a possibility. I'll have to think a bit about the details. I see RPL does this, but not recursively, so you can do, say, { 2 3 } SQ, but not { 2 3 { 5 7 } } SQ.
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Free42 question - SIGN - Werner - 09-10-2021, 08:40 AM
RE: Free42 question - SIGN - Thomas Okken - 09-10-2021 11:38 AM
RE: Free42 question - SIGN - John Keith - 09-10-2021, 06:20 PM
RE: Free42 question - SIGN - Werner - 09-10-2021, 12:20 PM



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