I have a hashmap having four values a,b,c,d and list having only a i want to see if the hashmap has the value a and print it.
hashmap.get('data') results a,b,c,d
list l is having a
how will i print only the value a
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
A Map stores Key-Value pairs. It offers a
values()method to get a collection of all values from the map.So basically you have to take your own list, get the values from the hashmap and check for every item in the list if it is a map value: