3 ms·
> Also, speaking of notation, I wonder why you used ':=' instead of '=' to define 'f'. There is no computation going on, right? In math, := is typically used t
by red_trumpet 3y ago
> Also, speaking of notation, I wonder why you used ':=' instead of '=' to define 'f'. There is no computation going on, right?
In math, := is typically used to denote a definition. Using equality (=) only makes sense if both sides of the equality sign already have a definition.
- eru 3y agoWell, to be fair, = is also very often used for definitions. And the reader has to figure out from context which meaning of = applies.
- chasd00 3y ago> In math, := is typically used to denote a definition. i mentioned this up-thread but is that why := is assignment in Pascal? Wasn't Pascal the main academic language there for a while?
- red_trumpet 3y agoYeah, I think that has the same origin. Though I'm not sure if programming languages or maths came first. Apparently, for programming languages it appeared first in ALGOL in 1958[1]. Edit: On math.SE[2] someone claims that it's notation borrowed form programming. Someone else claims that it was introduced by Bourbaki, which might predate programming, as Bourbaki started publishing in the 1930s. However, I couldn't find any evidence of this from skimming a few Bourbaki PDFs. [1] https://en.wikipedia.org/wiki/Assignment_(computer_science) https://en.wikipedia.org/wiki/Assignment_(computer_science) [2] https://math.stackexchange.com/a/25215/312406 https://math.stackexchange.com/a/25215/312406