size function:

  • Can also be called as count

  • Can also be called as length

  • Can also be called as len

Get the number of element in an array, the number of keys in an object or the number of characters in a string.

Examples:

  • running: (size [1, 2, 3, 4]) will give: 4

  • running: (size {"key-1": 1, "key-2": false}) will give: 2

  • running: (size "123") will give: 3

  • running: (size 50) will return nothing Because 50 is not an array, not an object nor a string.