Q. Why is dictionary termed as an unordered collection of objects?
Answer =
A dictionary is often referred to as an unordered collection of objects because the elements within a dictionary are not arranged in a specific order. In other words, the items in a dictionary do not have an inherent positional index like they do in a list or an array.
Instead of using numerical indices to access elements, a dictionary uses keys to uniquely identify and retrieve values associated with those keys. Each key in a dictionary must be unique, and it serves as a label or identifier for its corresponding value. The keys are used as a hash, allowing for efficient retrieval of values.
Why is dictionary termed as an unordered collection of objects?
ReplyDeleteAnswer =
Dictionary term as an unordered collection of object because in dictionary we can use any type of data types . but in key datatype should be immutable type.
You
DeleteWhy ????
DeleteMan above took the credit
ReplyDelete?
DeletePapa don vaibhav hai
ReplyDeleteWhy is dictionary termed as an unordered collection of objects?
ReplyDeleteAnswer =
Dictionary term as an unordered collection of object because in dictionary we can use any type of data types . but in key datatype should be immutable type.
???
Deletethank you sir by jaswanth 11 b
ReplyDeletePost a Comment
You can help us by Clicking on ads. ^_^
Please do not send spam comment : )