I have a = {1, 2, 3}
, and want to obtain Multinomial[1, 2, 3]
, which is 60
.
But when I input Multinomial[a]
, the input a
is the entire list so I got {1, 1, 1}
. That is, I need to separate a
from a single list into separated elements so that I can input them correctly.
Multinomial[Flatten[a]]
also doesn't work, since the last bracket can't be removed by Flatten
. What can I do?
Thanks!
Multinomial @@ a
, which in full form would beApply[Multinomial][a]
orApply[Multinomial, a]
: look upApply
. Think ofApply
as changing the head of an expression, in this case fromList
toMultinomial
. Tangentially, the arguments toMultinomial
should be aSequence
. $\endgroup$a /. List -> Multinomial
However, solution provided by @MarcoB is preferrable. $\endgroup$