Current collected state Current
Observed since 20 Oct, 19:09 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
Go back and forth from 2's complement like a charm
Go back and forth from 2's complement like a charm in NodeJS
npm i 2complement
decode = require('2complement');
console.log(decode.int2complement(32765).toString(2));
//1000000000000011
console.log(decode.complement2int(0b1000000000000011))
//-32765
console.log(decode.complement2int(decode.int2complement(-2000)));
//-2000
console.log("You rock");
//just a motivational quote. But you do <3
Download counts and popularity will appear here as the collector receives them.
This describes our collected data; it is not a security assessment.
Shared repository data · GitHub
Observed since 20 Oct, 19:09 UTC
No superseded metadata states collected. Unchanged observations do not create new revisions.
package:6a3f73786e0001e891b4faeaa39e050556d4101db9ae350e78fb59a256adf76f