java - HashMap string key -
I have a bug in my Android app and what I can not find is wrong, something that I think is problematic And I need your help
I have low embarrassment
hashmap & lt; String, string & gt; Numbers = New Hashmap & lt; String, string & gt; (); And I am including data like this,
numbers.put ("1", "one"); Numbers ("2", "two"); Then I search for it like this,
numbers.get ("1"); Is that correct? Please note that the above is working well, sometimes I see weird behavior as I mentioned earlier
update, I forgot "put in"
No, this will not work. You must put the same type of keys.
Maybe you mean
numbers ("1 one");
Comments
Post a Comment