Top "Hashmap" questions

A data structure that uses a hash function to map identifying values, known as keys, to their associated values

Which data structure would you use: TreeMap or HashMap? (Java)

Description | A Java program to read a text file and print each of the unique words in alphabetical order together …

java data-structures map hashmap treemap
Understanding the workings of equals and hashCode in a HashMap

I have this test code: import java.util.*; class MapEQ { public static void main(String[] args) { Map<ToDos, String&…

java hashmap equals hashcode
Simple hashmap implementation in C++

I'm relatively new to C++. In Java, it's easy for me to instantiate and use a hashmap. I'd like to …

c++ hashmap hashtable
Does "put" overwrite existing values?

New to hashtables with a simple question. For some reason googling hasn't gotten me a straight answer. Say I've got …

java hashmap hashtable
Is it possible to rename a Hashmap key?

I'm looking for a way to rename a Hashmap key, but i don't know if it's possible in Java.

java hashmap
HashMap with Null Key and Null Value

Consider the following Code : import java.util.*; class Employee { String name; public Employee(String nm) { this.name=nm; } } public class …

java collections null hashmap hashcode
SparseArray vs HashMap

I can think of several reasons why HashMaps with integer keys are much better than SparseArrays: The Android documentation for …

java android hashmap sparse-matrix
why HashMap Values are not cast in List?

I'm putting values into the hashmap which is of the form, Map<Long, Double> highLowValueMap=new HashMap<…

java arraylist collections hashmap
Best structure for list of key-value (integer, string) to be shuffled

I need to implement a structure in Java that is a key-value list (of types Integer-String) and I want to …

java hashmap hashtable shuffle linkedhashmap
ConcurrentHashMap and Hashtable in Java

What is the difference between a ConcurrentHashMap and a Hashtable in Java? Which is more efficient for threaded applications?

java hashmap hashtable