I need a function like the following,
boolean hasDuplicateValue(HashSet hs1, HashSet hs2) {
// return false;
}
This thread Efficiently finding the intersection of a variable number of sets of strings discusses a similar issue, however in this thread they also need the intersection values, which I do not need. So, it may add an additional computational complexity which I do not need.