You can have a Map as key but as you pointed out since a Map is (typically) mutable the key changes.
Read moreAre keys in a map unique?
The keys are unique in all maps . The difference between the various maps implementations concern the possibility of null keys, the order of iteration and concurrency issues.
Read moreAre keys in a map unique?
The keys are unique in all maps . The difference between the various maps implementations concern the possibility of null keys, the order of iteration and concurrency issues.
Read moreIs map key case sensitive in C++?
If you use the standard std::map associative container with std::string or std::wstring as key types, you get a case sensitive comparison by default .
Read moreIs key case sensitive?
While object properties are strings and they are case sensitive , you could use an own standard and use only lower case letters for the access. You could apply a String#toLowerCase to the key and use a function as wrapper for the access.
Read moreAre HashMap keys unique?
HashMap is a container that stores key-value pairs. Each key is associated with one value. Keys in a HashMap must be unique .
Read moreIs key unique in HashMap Java?
HashMap is a collection to store (key,value) pairs and According to the documentation of HashMap the keys are always unique . If you add a key which already exists(collision) in the hashmap, the old value will be replaced.
Read more