def check_chain_interaction(chainA, chainB, threshold):
    """
    This chain takes two BioPython PDB Chain objects, and return True is any atom CB of the first chain
    is closer than threshold to one atom CB of the second chain. Otherwise, returns False.
    """
    if chainA == chainB:
        return False
    else:
        for residue_A in chainA:
            for residue_B in chainB:
                for atom_A in residue_A:
                    for atom_B in residue_B:
                        if atom_A - atom_B < threshold:
                            print('Chains interact')
                            return True
                        else:
                            continue
        return False
