klyn.math.NDArray.zeros
method
public static zeros(notnull shape as Tuple) as NDArray<T>
Description

Creates a new NDArray with zeros from a tuple shape.

a = NDArray<Int>.zeros((2, 2))
Parameters
ParameterDescription
shapeFixed-size tuple of dimensions.
Returns

A new NDArray filled with 0.

Throws
  • NullException if shape is null at runtime; statically null arguments are rejected with TypeError.