Tell me about a time you parsed JSON data and implemented business logic from it.
For this coding exercise, implement process_records(json_text). The input is a valid JSON string containing a records array, where each record has an id, status, and numeric amount. Return a map containing the IDs of records whose status is approved, in input order, and the sum of their amounts. Assume the input follows the stated schema.
records array.id, a string status, and a numeric amount.approved contribute to the result.def process_records(json_text):