


![[top]](top.gif)
Synopsis:
product(n,f) -- compute the product f(0) * f(1) * ... * f(n-1).
i1 : product(5, i -> 2*i+1) |
See also:
Code:
-- ../../../Macaulay2/m2/lists.m2:76-82
product(ZZ,Function) := (n,f) -> (
s := 1;
g := x -> (
s = f x;
g = x -> s = s * f x);
scan(n,x -> g x);
s);



![[top]](top.gif)