import java.util.HashMap; import java.util.Iterator; import java.util.Map; import java.util.Set; /** * Created...