Skip to content

Basic properties

Uri edited this page Jul 14, 2021 · 3 revisions

Basics

next >

Shape - The dimensions of the array

Returns a list of integers indicating the size of the array in each dimension. For a matrix with n rows and m columns, shape will be (n m).

> (print (Shape [[1 2 3] [4 5 6]]))
(2 3)

The number of dimensions can be retrieved using lisp built-in function length.

> (print (length (Shape [[1 2 3] [4 5 6]])))
2

Next: Creation

Clone this wiki locally