log10

float log10(float num) 

Calculates the base 10 logarithm of a number.

Returns:

Base 10 logarithm of a number

Description:

log10() returns the base 10 logarithm of the number given by num .

Version:

PHP 3, PHP 4

See also:

exp() 
log() 

Example:

Calculate the base 10 logarithm
echo "The base 10 logarithm of 10 is ", log10(10); 

Get PHP Functions Essential Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.