Skip to main content

dict_items

No overview available.

def dict_items(
d: dict
) - > list

Converts a dictionary into a list of key-value tuples, facilitating iteration or serialization of mapping data.

Parameters

NameTypeDescription
ddictThe source dictionary whose items will be extracted into a list format.

Returns

TypeDescription
listA list of tuples where each tuple contains a key and its corresponding value from the input dictionary.