encode Number
minimal encoding of a number into a script element:
OP_0 to OP_16 if 0 <= n <= 16
OP_PUSHDATA(encodeNumber(n)) otherwise
Return
a script element that represents n
Parameters
n
input number
minimal encoding of a number into a script element:
OP_0 to OP_16 if 0 <= n <= 16
OP_PUSHDATA(encodeNumber(n)) otherwise
a script element that represents n
input number