(-) precedence
|
12-08-2022, 02:21 PM
(This post was last modified: 12-08-2022 02:22 PM by Maximilian Hohmann.)
Post: #5
|
|||
|
|||
RE: (-) precedence
Hello!
(12-08-2022 01:41 PM)Eddie W. Shore Wrote: The unary minus versus the subtraction operator should be address in school when discussing order of operations. It is a while ago that I left school (1980) but this topic was already addressed back then. But I must say that we had a very computer- and calculator-minded math teacher around the time when calculators started to be allowed for use in classes (1977 onward if I remember well). He used to bring his own private HP-97 to school, which must have cost him a month's salary or even more, to demonstrate calculus and simple programming techniques. So yes, I was made aware of those issues right from the start. When writing code, no matter what language or environment, I always use parentheses in these cases. Who knows which version of what compiler handles it which way? What are two parentheses against a working day lost for troubleshooting! Regards Max |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)