“Iterating over a dictionary object in Python will give you keys, no matter what Python feature you're using to do that iteration.”

Read more 👉 https://pym.dev/all-iteration-is-the-same/

#Python

All iteration is the same in Python

In Python, for loops, list comprehensions, tuple unpacking, and * unpacking all use the same iteration mechanism.