Exam 350-401 Question id=5587 Automation

import json def get_data(): test_json ="" { "response":[{ "managementlpAddress": "10.10.2.253", "memorySize": "3398101469", "serialNumber": "FXS1932Q2SE", "softwareVersion": "16.3.2", "hostname": "cat_9k" }], "version": "1.0" } ""

Which line must be added in the Python function to return the JSON object {'cat_9k': 'FXS1932Q2SE'}?

A. return (json.dumps({d['hostname']: d['serialNumber'] for d in json.loads(test_json)['response']}))
B. return (json.dumps({for d in json.loads(test_json)['response']: d['hostname']: d['serialNumber']}))
C. return (json.loads({d['hostname']: d['serialNumber'] for d in json.dumps(test_json)['response'}))
D. return (json.loads({for d in json.dumps(test_json)['response']: d['hostname']: d['serialNumber']}))

WARNING

the answers are mixed, do not specify in the comment number or the letter of the answer
please write answer#A instead A, answer#B instead B...
Subject:

only logged users can write comments