python output parameter 1

python output parameter

# There is no reason to, since Python can return multiple values via a tuple:

def func():
    return 1,2,3

a,b,c = func()

Here is what the above code is Doing:
1. The function func() returns a tuple of three values.
2. The tuple is unpacked into the variables a, b, and c.

Similar Posts