Product of list elements.
(lst)
| 273 | return isinstance(lst, list) |
| 274 | |
| 275 | def prod(lst): |
| 276 | """Product of list elements.""" |
| 277 | if len(lst) == 0: |
| 278 | return 0 |
| 279 | x = lst[0] |
| 280 | for v in lst[1:]: |
| 281 | x *= v |
| 282 | return x |
| 283 | |
| 284 | def strides_from_shape(ndim, shape, itemsize, layout): |
| 285 | """Calculate strides of a contiguous array. Layout is 'C' or |
no outgoing calls
no test coverage detected
searching dependent graphs…