for types such as list I can readily create an empty list to make this construct work:
 s = []
 s+= [1,2,3]  # result s assigned [1,2,3]
obviously useful in constructs like this:
 s=[]
 for v in (list1,list2,list3..):
   if condition : s+=v
Now I'm working with a user defined type, defined in a module that I cannot read or change.. I have to do this:
 s=0
 for v in (typefoo1,typefoo2,..):
   if condition :
    if s==0 :
     s=v
    else:
     s+=v
This works, but is ugly and occurs so often it is pretty annoying.
so.. is there a way to create an empty object such that the += operator would behave simply like a regular assignment= regardless of the type on the r.h.s?
Edit: I tried to keep the question generic deliberately, but for completeness the type in question is an Abaqus geometry sequence.

iterthe user defined type, or isv?sto0orNone, etc produces a 'unsupported operand type error on += ' error.iteris an iterable of objects other than the usual numbers that support addition among themselves?sumdoes not work on this type, although one workaround is to write my ownsumfunction specific to this type (Which is somewhat more elegant than the above )