Delete Key Property 2

If the key is equal to the key in the first entry in the "remaining" map, then remove this key from the "remaining" map and do not add it to the "processed" map. In other words, this entry is skipped. More formally:

output of function delete_entry where input key is key, map is [ pair (key, value), remaining ], and processed is kvs = output of function delete_entry where input key is key, map is remaining, and processed is kvs

Examples

output of function delete_entry where input key is "FL", map is [ pair ("FL", "Florida"), [ entry "AZ": "Arizona", [ entry "TX": "Texas", [ ] ] ] ], and processed is [ entry "ID": "Idaho", [ ] ] = output of function delete_entry where input key is "FL", map is [ entry "AZ": "Arizona", [ entry "TX": "Texas", [ ] ] ], and processed is [ entry "ID": "Idaho", [ ] ]

Quiz (1 point)

Please fill in the blank:

(result of deleting the entry with key "MT" in remaining entries [ entry "MT":"Mountain Time", [ entry "EST":"Eastern Time", [ ] ] ] and processed entries: [ entry "CST":"Central Time", [ ] ]) = (result of deleting the entry with key: "MT" in remaining entries: [ entry "EST":"Eastern Time", [ ] ] and processed entries: __________ )

Become a subscriber to save your progress, see the correct answer, and more!

Comments

Please log in to add comments