Skip to content

Esta página también está en español.

Léela en español

このページは日本語でも読めます。

日本語で読む

本页也有简体中文版本。

阅读简体中文版本

Length of a list (length)

Number of elements in a list.

How to write it

length(list)

list
The list. Takes a list.

Examples

  • length⁡([1,2,3])=3\displaystyle \operatorname{length}(\left[ 1, 2, 3 \right]) = 3
    length([1, 2, 3])

    In the solver, length([1, 2, 3]) gives 3.

    Open in the solver
  • list

    A list of the arguments.

  • last

    The last element of a list.

  • map

    Apply a function to every element of a list.

  • join

    Join lists into one.

  • map_thread

    Apply a function to corresponding elements of several lists.

  • intersection

    The elements that are in every one of some lists.