human
Complete this python program:
def autoassign(self, locals):
assistant
#Here is the Python program you requested.

    """Automatically assigns local variables to `self`.
    Generally used in `__init__` methods, as in:
    def __init__(self, foo, bar, baz=1): autoassign(self, locals())
    """
    for (k, v) in locals.iteritems():
        if (k == 'self'):
            continue
        setattr(self, k, v)