question: public static boolean isMonogamous ( Collection < Family > families ) { final HashSet < String > parents = new HashSet < > ( ) ; for ( Family f : families ) { if ( ! parents . add ( f . getFather ( ) ) ) { return false ; } if ( ! parents . add ( f . getMother ( ) ) ) { return false ; } } return true ; }
target:  Detects the presence of genetic non-monogamy within an set of families