Ready to begin
No records have been processed. Start with Next step.

Follow the dictionary as its keys and values change. Predict each lookup or update before revealing the next step.
Ready
No records have been processed. Start with Next step.
Predict the next key, whether it already exists, and the value that will be stored.
if (isKey(d,k)) {
value = d[k]
}
else {
# No value is stored for this key.
# Decide whether to create an entry or report a missing key.
}With d={7:0}, isKey(d,7) is True and d[7] is 0. isKey(d,99) is False. Do not assume a missing lookup automatically returns 0 or False in this pseudocode. The lab’s key 7 has a constructed zero specifically to demonstrate presence; it is not Aditya’s actual Chemistry mark.
keys(d) tells us the existing keys, not all possible keys. A present key may hold False, 0, [] or {}. None of these values makes the key disappear.
For d={7:False}, isKey(d,7) True or False?
True. The key exists even though its stored Boolean is False.
Does isKey({7:76},76) test whether 76 is a stored value?
No. It tests for a KEY 76, which is absent here.
What happens on an empty dictionary membership search?
No loop body executes and found remains False.