mirror of
https://github.com/musix-org/musix-oss
synced 2024-12-23 16:13:18 +00:00
23 lines
491 B
JavaScript
23 lines
491 B
JavaScript
|
var createMathOperation = require('./_createMathOperation');
|
||
|
|
||
|
/**
|
||
|
* Divide two numbers.
|
||
|
*
|
||
|
* @static
|
||
|
* @memberOf _
|
||
|
* @since 4.7.0
|
||
|
* @category Math
|
||
|
* @param {number} dividend The first number in a division.
|
||
|
* @param {number} divisor The second number in a division.
|
||
|
* @returns {number} Returns the quotient.
|
||
|
* @example
|
||
|
*
|
||
|
* _.divide(6, 4);
|
||
|
* // => 1.5
|
||
|
*/
|
||
|
var divide = createMathOperation(function(dividend, divisor) {
|
||
|
return dividend / divisor;
|
||
|
}, 1);
|
||
|
|
||
|
module.exports = divide;
|