Variable option count

  • Thread starter Florian Lindner
  • Start date
F

Florian Lindner

Hello,
how can I give an arbitrary number of options in a automated way to a
function?

Example.

I've the list A =

[
1
2
3
...
]

Now I want to give this list to a function so that it is the same for
function like:

f(1, 2, 3, ...)

How can I do that?

Thanks,
Florian
 
S

Simon Brunning

Hello,
how can I give an arbitrary number of options in a automated way to a
function?

Example.

I've the list A =

[1, 2, 3]

Now I want to give this list to a function so that it is the same for
function like:

f(1, 2, 3)

How can I do that?

f(*A)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,237
Messages
2,571,190
Members
47,827
Latest member
wyton

Latest Threads

Top