Let's say I have created two objects from class foo
and now want to combine the two. How, if at all possible, can I accomplish that within a function like this:
def combine(first, second):
first.value += second.value
del second #this doesn't work, though first.value *does* get changed
instead of doing something like
def combine(first, second):
first.value += second.value
in the function and putting del second
immediately after the function call?