klyn.math.NDArray.zeros
method
public static zeros(shape as ArrayList<Object>) as NDArray<T>:
Description
Creates a new NDArray with zeros.
dims = [2, 3]
a = NDArray<Int>.zeros(dims)
print(a.shape)
Parameters
  • shape Dimensions as objects converted to integers.
Returns
A new NDArray filled with `0`. ```klyn dims = [2, 3] a = NDArray<Int>.zeros(dims) print(a.shape) ```