hard
Single Answer
0

Which statement best represents the following JSON data from an interface? { "ipaddress": "192.168.1.2", "subnet_mask": "255.255.255.0", "defaultgw": "192.168.1.1", "routes": [ { "route": "10.0.0.0/8 via 192.168.1.10" "route": "0.0.0.0/0 via 192.168.1.1" } ] }

Answer Options

A

The interface data is incorrect because it is missing a comma after the routes.

B

The interface data is incorrect because it is missing a set of curly brackets around the first and second route.

C

The interface data is incorrect because it contains an illegal underscore character.

D

Nothing is wrong with the JSON data.

Correct Answer: B

Explanation

The collection of routes contains two individual route statements that are named route (singular). All collections must be contained within square brackets, also called braces. All of the other options are incorrect. The corrected JSON should have separate objects for each route: {"route": "10.0.0.0/8 via 192.168.1.10"}, {"route": "0.0.0.0/0 via 192.168.1.1"}.

json
syntax
troubleshooting
arrays
objects