Exam 350-401 All QuestionsBrowse all questions from this exam
Question 940

DRAG DROP

-

Drag and drop the code snippets from the bottom onto blanks in the Python script so that the program changes the IP address and saves it as a new JSON file on the disk. Not all options are used.

    Correct Answer:

Discussion
SeMo0o0o

i hate such questions :(

AzraelOmbrixa

brutal question.

SeMo0o0o

given answer is correct The script reads a JSON file, modifies an IP address within the JSON structure, and then saves the modified JSON in both compact and indented formats into two separate files.

sheetal2019

given ans should be correct

DarthObiGuan

This is what I can gather 1. Open some file which contains json data. 2. Read that entire file into a string (json.read) 3. Converts the json string into a python dictionary array (json.load) 4. Modify the IP address of Gi0 to 192.168.1.2 in the python dictionary array 5. Convert the python dictionary array into back to a json string without identation (json.dump) 6 Convert the python dictionary array into back to a json string with indentation (json.dump) 7. Write the json string with and without identation to 2 seperate files (json.write) So I think the provided answer is correct.

5eba813

anyone can confirm ?

cloud29

Anyone can explain this?