/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
	public static void main (String[] args) throws java.lang.Exception
	{
		Set<Integer> set = new HashSet<Integer>(Arrays.asList(10,30,20,10));
		int maxValueInSet = Collections.max(set);
		
		Map<String, Integer> hashMap = new HashMap<String, Integer>() {{
		    put("a", 20);
		    put("b", 30);
		    put("c", 10);
		    put("d", 40);
		    put("e", 30);
		}};
		
		for (Map.Entry<String, Integer> entry: hashMap.entrySet()) {
		    if (entry.getValue().equals(maxValueInSet)) {
		        System.out.println(entry.getKey());
		    }
		}
	}
}