Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

base-log

0.0.2 • Public • Published

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

Install

npm i base-log

DownloadsWeekly Downloads

4

Version

0.0.2

License

MIT

Last publish

Collaborators

  • avatar