0.0.2 • Published 8 years ago

base-log v0.0.2

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

base-log

Returns the logarithm of a number (y) with specified base (x). logxY

Install

npm install base-log
bower install base-log

Usage

baseLog(base, number) => logarithm

const baseLog = require('base-log');

console.log(baseLog(5, 25)); // 2
console.log(baseLog(7, 49)); // 2
console.log(baseLog(2, 8)); // 3
console.log(baseLog(4, 64)); // 3
console.log(baseLog(2, 16)); // 4

Test

npm test

License

MIT