Start · Sprachen · PHP · Referenz · log10

log10

Funktion

Logarithmus zur Basis 10.

seit PHP 4.0.0 Kategorie: math

Signatur

log10(float $num): float

Beschreibung

Für die Stellenzahl einer Zahl: (int) log10($n) + 1.

Parameter

Name Typ Default Beschreibung
$num Pflicht float Argument.

Rückgabewert

Typ
float
Beschreibung
log10.

Beispiele

Basis

<?php

echo log10(1000); // 3