def to_script_pubkey
      v = ver == 0 ? ver : ver + 0x50
      ([v, prog.length].pack("CC") + prog.map{|p|[p].pack("C")}.join).unpack('H*').first
    end
def to_script_pubkey
      v = ver == 0 ? ver : ver + 0x50
      ([v, prog.length].pack("CC") + prog.map{|p|[p].pack("C")}.join).unpack('H*').first
    end
witness program
 Returns segwit script pubkey which generated from witness version and witness program.