as my question says I would like to insert my arraylist items into a hashmap.
This is my HashMap.
HashMap<String, Integer> unSorted = new HashMap<String, Integer>();
This is my ArrayList.
arrayList.add("1");
arrayList.add("2");
Adding into Hashmap.
unSorted.put(arrayList,50);
I am pretty sure I can't add an arraylist like this. I forgot I've got to iterate the arrayList and insert the values one by one.
How am I going wrong ?
Thank you for your time !