JSON Array

JSON Array: An array is an ordered collection of values. An array begins with [ (left bracket) and ends with ] (right bracket). Values are separated by , (comma).

JSON Array Syntax:
array

 [] [ elements ]

elements

 value value , elements

value

 string number object array true false null

Example 1:

[ "Ford", "BMW", "Fiat" ]  

Example 2:

// array[true, false, 0, 1, 2, 1.5, "A", "Yes"]// multidimensional array[  [    ["A", "B", "C"],    ["D", "E", "F"]  ], [    ["G", "H", "I"],    ["J", "K", "L"]  ], [    ["M"],    ["N"],    ["O"]  ]]

 

Example 3: combination of array and object

{ "employees":[    {"name":"Ram", "email":"ram@gmail.com", "age":23},    {"name":"Shyam", "email":"shyam23@gmail.com", "age":28},    {"name":"John", "email":"john@gmail.com", "age":33},    {"name":"Bob", "email":"bob32@gmail.com", "age":41}   ]}