What is the correct result?
|
03-20-2024, 09:21 PM
Post: #21
|
|||
|
|||
RE: What is the correct result?
(03-20-2024 10:31 AM)vaklaff Wrote: ... and here we go :-) OK, back in the early days of COBOL didn't they assume a businessman could simply dictate a progam to a secretary, even illustrating the process with a photo? Remember kids, "In a democracy, you get the government you deserve." |
|||
03-21-2024, 04:44 AM
Post: #22
|
|||
|
|||
RE: What is the correct result?
As someone conversant with Fortran (high school and college), Basic (Commodore Pet and others), COBOL (work), and other computer languages, I really wanted to learn APL because it looked cool. I went to a computer swap meet while in San Francisco visiting a friend, and picked up a floppy disc with IBM’s TryAPL2 on it - an interpreter for APL code with examples. It was a great way to learn it without sinking a lot of money into a development environment (that came later). One year I entered a contest in Byte Magazine to write some APL code to solve a problem, and never heard back from them. Nor did they publish the follow-up article on it. I think it was Bill Machrone who posed the problem. I also got into J (jsoftware.com), which Kenneth Iverson and Roger Hui came up with as “APL without the funny characters”, using regular symbols like “,” and “;” and “<“ and “?” to do pretty much the same thing: have a simple way to write terse code. It confuses me because it is made up of verbs and adverbs and nouns and gerunds, and I never learned to diagram a sentence.
|
|||
03-21-2024, 03:29 PM
(This post was last modified: 03-21-2024 07:22 PM by SlideRule.)
Post: #23
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 04:44 AM)DGM Wrote: As someone conversant with Fortran (high school and college), Basic (Commodore Pet and others), COBOL (work), and other computer languages, I really wanted to learn APL … It confuses me because it is made up of verbs and adverbs and nouns and gerunds, and I never learned to diagram a sentence. I found this article, BASIC, FORTRAN and COBOL in Chemical Engineering magazine {vol 90 #5, 1983 ⁄07 ⁄25, pages 81-84) by Namir C. Shammas a most edifying read on the above referenced topic. Give it a go! BEST! SlideRule ps: there is a positive follow on comment to this article in vol. 90, #21 {1983 ⁄10 ⁄17}, page 5 |
|||
03-21-2024, 07:04 PM
Post: #24
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 03:29 PM)SlideRule Wrote:(03-21-2024 04:44 AM)DGM Wrote: As someone conversant with Fortran (high school and college), Basic (Commodore Pet and others), COBOL (work), and other computer languages, I really wanted to learn APL … It confuses me because it is made up of verbs and adverbs and nouns and gerunds, and I never learned to diagram a sentence. Broken link |
|||
03-21-2024, 07:08 PM
Post: #25
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 04:44 AM)DGM Wrote: ... I also got into J (jsoftware.com), which Kenneth Iverson and Roger Hui came up with as “APL without the funny characters”, using regular symbols like “,” and “;” and “<“ and “?” to do pretty much the same thing: have a simple way to write terse code. J seems even less readable than APL to me due to the seemingly random use of ASCII characters for mathematical operations. And people think RPL is unreadable. Harrumph! |
|||
03-21-2024, 07:22 PM
Post: #26
|
|||
|
|||
RE: What is the correct result? | |||
03-21-2024, 08:24 PM
(This post was last modified: 03-22-2024 04:24 PM by carey.)
Post: #27
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 07:08 PM)John Keith Wrote:Yes, while APL’s eventual character set (not fully formed in Iverson’s 1962 book “A Programming Language”) was constrained to use characters (glyphs) that could be included in an IBM selectric typewriter font ball, at least APL glyphs evoke some visual connection to their name or function (e.g., grade up ⍋, grade down ⍒), little visual connection between ASCII symbols and name is found in J, whose appearance has justifiably been described as “line noise.” While a pain to use, APL glyphs are an endearing feature of APL, and are iconic (pun intended).(03-21-2024 04:44 AM)DGM Wrote: ... I also got into J (jsoftware.com), which Kenneth Iverson and Roger Hui came up with as “APL without the funny characters”, using regular symbols like “,” and “;” and “<“ and “?” to do pretty much the same thing: have a simple way to write terse code.J seems even less readable than APL to me due to the seemingly random use of ASCII characters for mathematical operations. And people think RPL is unreadable. Harrumph! It may be of interest that ELI is a largely ISO APL compatible APL variant (with additional features e.g., complex #’s, tables, etc.) that also uses an ASCII character set, but unlike J, ELI’s ASCII character set bears at least some visual connection with APL glyphs, names or functions (e.g., compare iota ⍳ (iota in APL) to ! (iota in ELI). Having such visual cues to APL glyphs while using an ASCII font is a nice feature of ELI. |
|||
03-21-2024, 08:58 PM
Post: #28
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 08:24 PM)carey Wrote: It may be of interest that ELI is a largely ISO APL compatible APL variant (with additional features e.g., complex #’s, tables, etc.) that also uses an ASCII character set, but unlike J, ELI’s ASCII character set bears at least some visual connection with APL glyphs, names or functions (e.g., compare iota ⍳ (iota in APL) to ! (iota in ELI). Having such visual cues to APL glyphs while using an ASCII font is a nice feature of ELI. Eli to C compiler for speeding up an APL application, and possible multicore parallelization? Oh my, yet another task to add to my backlogged to-do list Thanks for the reference Remember kids, "In a democracy, you get the government you deserve." |
|||
03-21-2024, 09:19 PM
(This post was last modified: 03-21-2024 11:17 PM by carey.)
Post: #29
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 03:29 PM)SlideRule Wrote: I found this article, BASIC, FORTRAN and COBOL in Chemical Engineering magazine {vol 90 #5, 1983 ⁄07 ⁄25, pages 81-84) by Namir C. Shammas a most edifying read on the above referenced topic. Give it a go! This is a very nice 1983 article. Thank you 'SlideRule' for posting it and well done, Namir, for writing it! The 3 listings it contains of a chem engineering program, in BASIC, Fortran and Pascal, are like a Rosetta Stone for comparing the languages. Just one comment about the last paragraph sentence "C is similar to Pascal" is that Brian Kernighan (The C Programming Language, Kernighan and Richie, 1983) might disagree :) |
|||
03-22-2024, 04:18 PM
(This post was last modified: 03-22-2024 04:28 PM by johnb.)
Post: #30
|
|||
|
|||
RE: What is the correct result?
(03-21-2024 08:24 PM)carey Wrote:(03-21-2024 07:08 PM)John Keith Wrote: J seems even less readable than APL to me due to the seemingly random use of ASCII characters for mathematical operations. And people think RPL is unreadable. Harrumph!Yes, while APL’s eventual character set (not fully formed in Iverson’s 1962 book “A Programming Language”) was constrained to use characters (glyphs) that could be included in an IBM selectric typewriter font ball, at last APL glyphs evoke some visual connection to their name or function (e.g., grade up ⍋, grade down ⍒), little visual connection between ASCII symbols and name is found in J, whose appearance has justifiably been described as “line noise.” While a pain to use, APL glyphs are an endearing feature of APL, and are iconic (pun intended). And then, there are software people in the world who make programming languages that are deliberately warped or obtuse: Intercal (created as a joke at Princeton in 1972), which stands for "Computer Language With No Pronounceable Acronym", was one of the earliest. (http://www.catb.org/~esr/intercal/) There are others, some with even more delicious names: Maleboge (named after Dante's 8th Circle of Hell), LOLCode*, and BrainF**k. The "Whitespace" language treats only the whitespace characters (space, tab, and return) as syntactically significant, rendering it devilishly difficult to read, but also allowing the developer to steganographically embed their real program in a trivial C, Pascal, or other program, enabling plausible deniability. (Put that in your good programming practices pipe and try to smoke it!) Reading RPL is, by comparison to these, like reading "Fun With Dick and Jane." And then there was my own humble contribution, PATHETIC. So named because most programmers had written at least one program in it anyway, as evidenced by someone looking over your shoulder at a printout and commenting, "Gee, that's PATHETIC." ______________ * LOLCode version of "Hello World": Code: HAI Daily drivers: 15c, 32sII, 35s, 41cx, 48g, WP 34s/31s. Favorite: 16c. Latest: 15ce, 48s, 50g. Gateway drug: 28s found in yard sale ~2009. |
|||
04-12-2024, 10:50 PM
(This post was last modified: 04-12-2024 10:58 PM by Matt Agajanian.)
Post: #31
|
|||
|
|||
RE: What is the correct result?
Hi all.
Here’s a new one. While following another of those 'What’s the answer' posts, from my post a FB poster stated that "Implied multiplication has no priority." Then, in another statement I made about PEJMDAS, the individual commented Casio and Sharp are, get this, incorrectly programmed and TI is the most reliable. What do you make of this? |
|||
04-13-2024, 01:26 AM
(This post was last modified: 04-13-2024 01:37 AM by carey.)
Post: #32
|
|||
|
|||
RE: What is the correct result?
(04-12-2024 10:50 PM)Matt Agajanian Wrote: Hi all. There is no mystery. But before replying directly to the question, it seems important to recognize that operator precedence is a mathematical convention invented by people (as in Kronecker’s saying: ”God made the integers; all else is the work of man”). People did arithmetic before calculators and there was no universally agreed upon operator precedence before around 1920. As nicely detailed in this YouTube video by an Australian math video creator (starting around 6:45 in the clip) calculators created the recent chaos for math teachers, students and calculator users (but not for professional mathematicians). As explained in the video (which includes material from Casio and TI managers) North American teachers prefer the (current) TI convention (PEMDAS) while elsewhere in the world PEJMDAS is preferred. (Mercifully, the video defines these terms! :) Because of TI’s long-standing relationship with the National Council of Teachers of Mathematics (NCTM), the preference of N.A. teachers for the TI convention is not surprising and might be an example of the tail wagging the dog. Thus, the cited FB comment claiming that TI is more reliable and that Casio and Sharp are wrong appears to simply reflect a geography-based preference and not a universal truth. An interesting sidenote is that at 11:35 in the video the operator precedence for the HP35s appears to throw the video creator for a loop! |
|||
04-13-2024, 01:52 AM
Post: #33
|
|||
|
|||
RE: What is the correct result?
Carey (and the other MoHPC members):
Thanks for setting the record straight. Carey, your perspective has been mine since I saw the video I'll post later. In the multitude of YT (not FB) videos I've seen, there's one which is quite technical and very telling. It highlights the trains of thought as well as how distinguished mathematicians have handled the PEJMDAS/PEDMAS dichotomy, Once I find the video, I'll post the link |
|||
04-13-2024, 01:56 AM
Post: #34
|
|||
|
|||
RE: What is the correct result? | |||
04-14-2024, 01:44 AM
Post: #35
|
|||
|
|||
RE: What is the correct result?
Sorry for the double post. But here is a response I got from my exchange on FB:
Casio has been sued in multiple countries for changing the programming in their calculators depending on the market they're selling to, so they really aren't a remotely reputable brand. Has anyone heard about this? |
|||
04-15-2024, 11:06 AM
(This post was last modified: 04-15-2024 11:28 AM by Maximilian Hohmann.)
Post: #36
|
|||
|
|||
RE: What is the correct result?
Hello!
(04-14-2024 01:44 AM)Matt Agajanian Wrote: Sorry for the double post. But here is a response I got from my exchange on FB: "FB" means Facebook? I don't use it and am not really familiar with the abbreviation. (04-14-2024 01:44 AM)Matt Agajanian Wrote: Has anyone heard about this? First this answer: No. And I have even bothered to search in different languages. (04-14-2024 01:44 AM)Matt Agajanian Wrote: Casio has been sued in multiple countries for changing the programming in their calculators depending on the market they're selling to, so they really aren't a remotely reputable brand. I completely disagree with everything contained in this statement. Really everything. Fully and totally. 1. Being sued does not make a brand non-reputable. Only being convicted. Google does not find any reference to lawsuits and no refrence to verdicts against Casio either. At least I could not find them using Google. 2. Localising products for different parts of the world is totally normal and happens everywhere. Ever seen a Mercedes delivered to the United Kingdom? It has the steering wheel on the "wrong side". To my knowlede, nobody ever sued Mercedes for adapting their products to local conditions. To my knowledge, no one ever sued HP either for delivering calculators to Europe which show a comma instead of a decimal point. And even if someone did, that would not make HP a "not remotely reputable brand", wouldn't it? 3. Casio calculators are and remain the intellectual property of Casio. They can do with them and their microcoding what they want. If they decide to change the order of operations they are free to do so as they please. Casio does not even hide these things from their customers because they clearly include the intended marketing region in the product designation, e.g. "fx-810DE CW" where "DE" stands for Deutschland and means, that the calculator is compliant with german school and exam regulations. Additionally, every instruction manual of every calculator from Casio can be downloaded for free by anybody, even without purchasing one. So if unsure, look inside the maual before buying. 4. Sueing people and companies over trivialities is a very American thing (sorry to say that) and certainly not common "in multiple countries". In my part of the world, no court would even accept a lawsuit of someone complaing that a product behaves exactly as advertised. Even if the predecessor behaved differently. And even if someone would be accepted before court with such a claim, the case would not end with a verdict but with a judicial settlement instead. By which Casio will take back the calculator in question and reimburse the 25 Euros to the plaintiff, even if the unit is already out of warranty. The court costs and legal fees will be split in half, leaving the plaintiff with a four-figure bill over a 25 Euro calculator... Regards Max NB: Of course I am still interested in those court cases in multiple countries if someone can find them! |
|||
04-15-2024, 01:12 PM
(This post was last modified: 04-15-2024 01:13 PM by Eddie W. Shore.)
Post: #37
|
|||
|
|||
RE: What is the correct result?
My first thought is go with what Tony Barlow said in Gene Wrights' presentation when Barlow reviewed the ill-fated never-released TI-88:
"1. Kill Implied Multiplication. 2. Kill Implied Multiplication. 3. Kill Implied Multiplication." https://www.youtube.com/watch?v=wl16wzmn3wA Scroll to 13:24. I'm for consistency. I would do what CAS calculators that allow more than one-character variable names: require multiplication symbols (dots, crosses, asterisks) in between operators to be multiplied. Every time. In programs I write, I put multiplication symbols every time. Yes it costs me some bytes but clarity is well worth the cost. Notation like f(expression) should always be a function call, and 2(expression) would return an error message, requiring a multiplication symbol and/or perhaps an extra set of parenthesis if we really meant to prioritize (2 * (expression)). Second, PEMDAS vs PEJMDAS seems to align with the way the world views the standard units in science: PEMDAS: ft, sec, lbs (well, at least in the United States' teachers) PEJMDAS: m, sec, kg Third, I'm not a fan of "pick a lane" but in this case, the world needs to pick a method and stick to it, make it universal so there is no confusion. Americans, especially American teachers may have to swallow their pride on this one. |
|||
04-15-2024, 02:05 PM
(This post was last modified: 04-15-2024 08:29 PM by Steve Simpkin.)
Post: #38
|
|||
|
|||
RE: What is the correct result?
Additional discussions of this implicit multiplication topic:
https://www.hpmuseum.org/forum/thread-11916.html https://www.hpmuseum.org/forum/thread-8982.html https://www.hpmuseum.org/cgi-sys/cgiwrap...ead=246984 https://archived.hpcalc.org/museumforum/...pid=247646 Wikipedia also has a description on Order of Operations and the ambiguity it can have. https://en.wikipedia.org/wiki/Order_of_o...iplication TI's interpretation depends on the model: https://education.ti.com/en/customer-sup...sage/11773 6/2(2+1) Facebook post with 8.3K comments! https://www.facebook.com/story.php/?stor...4238442691 |
|||
04-15-2024, 02:27 PM
Post: #39
|
|||
|
|||
RE: What is the correct result?
Normally, I don't chime in on these discussions, however, I have a simple observation - the expression axn seems to affirm arguments both favoring and disfavoring implied multiplication {neh?}? It seems we have lost sight of the original argument over ambiguity in math notation and the posturing of parenthesis free notation (RPN, etc.) as a working solution {praxis}.
my pennies worth BEST! SlideRule |
|||
04-15-2024, 03:49 PM
Post: #40
|
|||
|
|||
RE: What is the correct result?
(04-15-2024 11:06 AM)Maximilian Hohmann Wrote: Hello! Thanks for the extensive explanation. Those quotes were from another Facebook member. That response was not mine. I don't know where that Facebook member got the info from. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 4 Guest(s)