Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

args in python

def func(*args):
    x = []          # emplty list
    for i in args:
        i = i * 2
        x.append(i)  
        y = tuple(x) # converting back list into tuple
    return y
        
tpl = (2,3,4,5)        
print(func(*tpl))
 
PREVIOUS NEXT
Tagged: #args #python
ADD COMMENT
Topic
Name
4+5 =