def combine(self, pubkeys):
assert len(pubkeys) > <NUM_LIT:0><EOL>outpub = ffi.new('<STR_LIT>')<EOL>for item in pubkeys:<EOL><INDENT>assert ffi.typeof(item) is ffi.typeof('<STR_LIT>')<EOL><DEDENT>res = lib.secp256k1_ec_pubkey_combine(<EOL>self.ctx, outpub, pubkeys, len(pubkeys))<EOL>if not res:<EOL><INDENT>raise Exception('<STR_LIT>')<EOL><DEDENT>self.public_key = outpub<EOL>return outpub<EOL>
Add a number of public keys together.