As we all know map doesn't allow duplicate values,but is there a way to add duplicate values to a map.I need to add duplicate Key and Value to a map such as
1 A
1 C
1 D
2 D
2 G.
When its put to a map it will return only 1 D and 2 G.I have tried google Multimap but having problem with iteration .Is there any possibility to solve this or what approach can be taken to allow duplicate value to a map.