def extend_safe(target, source):
 for elt in source:
  if (elt not in target):
   target.append(elt)

def extend_safe ( target , source ) : for elt in source : if ( elt not in target ) : target . append ( elt )
extends source list to target list only if elements doesnt exists in target list .