Arrays
Array value syntax — ordered, comma-separated collections of values.
Syntax
array = "[" [ value *("," value) ] "]"Structural characters
Symbol
Name
Unicode
Description
Valid forms
[] # Empty array
[apple, banana, cherry] # String values
[1, 2, 3] # Number values
[T, F, N] # Boolean and null values
[{x:1}, {y:2}] # Array of objects
[1, [2, 3], [4, [5, 6]]] # Nested arrays
[[1,2],[3,4]] # 2D arrayOptional behaviors
Whitespace and formatting
Empty array
Nesting
Comments
Invalid forms
Corrected versions
Preservation of structure
See Also
Last updated
Was this helpful?
