Q. Why can't Lists be used as keys?


Answer =

Lists cannot be used as keys in a dictionary because they are mutable. And a Python dictionary can have only keys of immutable types.

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post