[Tutor] Feeding a list into a function as arguments

Andreas Kostyrka andreas at kostyrka.org
Thu Apr 26 10:47:30 CEST 2007


* Stevie Broadfoot <coollikestevie at gmail.com> [070426 09:56]:
>    I have a list... say for example
> 
>    list = ["hello", "there"]
> 
>    and i have a function
> 
>    def printout(firstword, secondword):
>        print firstword
>        print secondword
> 
>    and i want to call
> 
>    the function like this
> 
>    printout(list)
printout(*list)

Andreas


More information about the Tutor mailing list