Mathf.Log10

Unity · Версия 2020.3 LTS · Scripting · Mathf

Mathf.Log10

Объявление

public static float Log10(float f);

Описание

Возвращает логарифм указанного числа по основанию 10.

using UnityEngine;

public class Example : MonoBehaviour
{
    void Start()
    {
        // logarithm of 100 in base 10
        // Prints 2
        print(Mathf.Log10(100));
    }
}

Обновлено 17 ноября 2026 г.