What symbol does JSON code begin and end with?

Group of answer choices

A square bracket

An asterisk

A curly brace

Dashes

1 answer

JSON code begins and ends with a curly brace if it's an object, or with square brackets if it's an array.

  • JSON objects begin and end with curly braces {}.
  • JSON arrays begin and end with square brackets [].

Since the question refers to JSON code in general, the correct answer would be A curly brace if we consider it in terms of JSON objects. Otherwise, it's important to note that arrays start and end with square brackets.