DEV Community

Shahriyar Al Mustakim Mitul
Shahriyar Al Mustakim Mitul

Posted on

Dictionary is unordered but list is not

Dictionary is unordered . What do I mean by that?
Image description

You can tell that these 2 dictionaries are equal . Although the order of the keys are not same. But the values are same.
Image description

But for lists, the order does matter.
Image description
These 2 lists are not equal as the order of the data or value is not same.

SO, this is ordered & unordered means.

Keep that in mind dear!

Top comments (0)