1.0.1 • Published 7 years ago

cointoss v1.0.1

Weekly downloads
2
License
MIT
Repository
github
Last release
7 years ago

cointoss

Toss a cryptographically secure coin.

What?

Exports a function that, when called, returns either true or false randomly and cryptographically securely.

Why?

Because if there's one thing npm needs more of, it's 3-line packages.

How?

const cointoss = require('cointoss');
if (cointoss()) {
	console.log("Heads");
} else {
	console.log("Tails");
}
1.0.1

7 years ago

1.0.0

7 years ago