declare fun {Product Ls} {Iter Ls 1} end fun {Iter Ls Acc} case Ls of E | Es then if E == 0 then 0 else {Iter Es Acc*E} end else Acc end end {Product 3|4|0|7|8|nil} = {Iter 3|4|0|7|8|nil 1} = {Iter 4|0|7|8|nil 3} = {Iter 0|7|8|nil 12} = 0