3 ms·
In python, f(a, b) is a function applied to two arguments and f((a, b)) is a function applied to a single tuple.
by faho 5y ago
In python, f(a, b) is a function applied to two arguments and f((a, b)) is a function applied to a single tuple.
- zgamy 5y agoBut is that closer to math notation as claimed in this thread? https://en.wikipedia.org/wiki/Argument_of_a_function https://en.wikipedia.org/wiki/Argument_of_a_function "For example, the binary function f(x, y) = x + y has two arguments, x and y, in an ordered pair (x, y)." So, function application to an ordered pair, i.e., a tuple, does not use double parentheses. Also, of course, currying in Python is atrocious.