Let f
be a function with 2 arguments. I do not really understand why the syntax:
f(1,2,)
actually works (note the ending comma)? It looks like the arguments are seen as a tuple, but in this case, if g
is a function with 1 argument, why g(1)
is working (instead of g(1,)
in the same way we have to write (1,) to get the tuple with only one element)?
I think it's a Python's specification question but I do not know where to search.