3 ms·
hmm... c = sqrt(a*a + b*b) (setf c (sqrt (+ (* a a) (* b b))))
by GregBuchholz 12y ago
hmm...
c = sqrt(a*a + b*b)
(setf c (sqrt (+ (* a a) (* b b))))
- thoth 12y agoAmusing... but to be fair, this is also an operator precedence issue where C is letting you drop several pairs.
- GregBuchholz 12y ago>where C ...I think operator precedence allows the removal of the parenthesis for at least: Ada, C, C++, D, Dylan, Erlang, Fortran, Go, Haskell, Icon, Java, Javascript, Julia, Lua, Mathematica, OCaml, Pascal, Perl, Prolog, Python, QBasic, R, Ruby, Scala, and TCL.
- kazagistar 12y agoI don't see how that is supposed to be a valid excuse. Non-lisps tend to support operator precedence, reducing the number of parens significantly. Thus, the argument "other languages require the same number of parens" is completely false.