code: public static <T> void removeValue(Map<?,T> map, T value) {
  		ArrayList<Object> keys = new ArrayList<>();
  		for (Map.Entry<?,T> e : map.entrySet())
  			if (e.getValue().equals(value))
  				keys.add(e.getKey());
  		for (Object key : keys)
  			map.remove(key);
  	}
docs: Remove all keys associated with the given value.