I want to write a script like this:
if there is bond between atom1 and atom2
elif there is no bond between atom1 and atom2
do something else.
But I don't know how to check the bond existence between atoms in Pymol.
Thanks in advance for any idea how to do it.