A network engineer inspects the JSON body returned by a switch API for one interface: { "name": "GigabitEthernet0/1", "mtu": 1500, "enabled": true, "vlans": [10, 20, 30] } The engineer must explain to a colleague how the individual values in this document are encoded according to the JSON data format. Which two statements correctly describe the encoding of the values shown? Select TWO.
- AThe value 1500 is a JSON number and is written without surrounding quotation marks. Correct
- BThe value of "vlans" is a JSON array, an ordered list of values enclosed in square brackets. Correct
- CThe value true is a quoted JSON string because every JSON value must be wrapped in quotation marks.
- DThe value "GigabitEthernet0/1" is a JSON number because it contains the digits 0 and 1.
- EThe pair "mtu": 1500 is itself a JSON array because it lists a name beside a value.
Why A is correct: JSON encodes numeric values as bare literals, so 1500 carries no quotes and is interpreted as a number rather than text.
Why B is correct: Square brackets delimit a JSON array, and the comma-separated members 10, 20 and 30 form the ordered list of values it holds.
Why C is wrong: It is tempting to treat all values as text, but true is a bare JSON boolean literal and is wrong because quotes would instead make it a string.
Why D is wrong: Embedded digits look numeric, yet the double quotes make this a JSON string, so classing it as a number misreads the encoding.
Why E is wrong: A name beside a value resembles a list, but this is a key-value member of a JSON object, not an array delimited by square brackets.