Hai friends..
Assume a HashMap has set of key / value pairs.
I need to put new key/Value pair.
But one condition i have to check first ,before adding the Key to HashMap it hasto be checked with previous stored value.
check if it is available or not ?
HashMap h1=new HashMap("one",two");
1. Now i am going to insert "two" (key) to the HashMap,before i need to insert i have to check with previous value="two"?
Then next scenario i have to check value of current insertion has to be checked with previous stored Key and value
2. Now i am going to insert value "two" to the HashMap , before in need to insert i have to check with previous Key="one" and previous value="two"
You people suggest any logic for this ?