Map Comparion Doubt

Hi Experts...
I have a map whose values are displayed as shown below.

I need to display the results of the comparison only if the key is present in another map say LinkedHashMap<String,Integer> firstMap = new LinkedHashMap<String,Integer>();
How do i achieve this.
Please help...
for(final Entry<String,Boolean> entry : comparisonResult.entrySet())
{ 
		
System.out.println("Entry:" + entry.getKey() + ", value: " + entry.getValue()); 
		
}

Open in new window

gaugetaAsked:
Who is Participating?
 
Gurvinder Pal SinghConnect With a Mentor Commented:
0
 
Gurvinder Pal SinghCommented:
check if the
if( map.get( entry.getKey( ) ) == null )
{
  //value doesn't exist
}
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.