def accumulator(init, update):
    return (
        init + len(update)
            if isinstance(init, int) else
        init + update
    )
Generic accumulator function.
dataset/ETHPy150Open jjangsangy/py-translate/translate/coroutines.py/accumulator