Returns an iterator over the dictionary’s key-value pairs.
- Xcode 10.2+
- Swift Standard Library
An iterator over the dictionary with elements of type
(key: Key, value: Value).
Iterating over a dictionary yields the key-value pairs as two-element tuples. You can decompose the tuple in a
in loop, which calls
make behind the scenes, or when calling the iterator’s
next() method directly.