ES6 - Math.log10(x) Function


Advertisements

Returns the base 10 logarithm of X.

Syntax

Math.log10(x)    

Parameter

  • X − represents a number

Example

console.log("---Math.log10()---") 
console.log("Math.log10(10): "+Math.log10(10)) 
console.log("Math.log10(16.7): "+Math.log10(10))         

Output

---Math.log10()--- 
Math.log10(10): 1 
Math.log10(16.7): 1           
es6_math.htm
Advertisements