The functions work because only one UID is ever in the context, referencing the same object through multiple families.
The "For each" is needed because the system condition "Pick by evaluate" won't implicitely loop through all famEnemyMelee UIDs. As a rule of thumb, when you are using expressions and can't use "Self" to reference your object, take for granted that you'll need a for each.