log10(3)
π log10(3) β bestie edition π
Okay so bestie, welcome to the log10 manual page from the Library Functions Manual β she's serving base-10 logarithm realness and honestly? Iconic. Lowkey the whole family is here: log10, log10f, and log10l π
β¨ NAME β¨
log10, log10f, log10l β the base-10 logarithmic function, aka the way that you find out what power of ten gives you x. No cap. π
π LIBRARY π
Math library (libm, -lm) β so like, remember to link her or she will not show up. Fr fr. π«Ά
πΈ SYNOPSIS πΈ
#include <math.h>
double log10(double x);
float log10f(float x);
long double log10l(long double x);
π§ Feature Test Macro Requirements for glibc (see feature_test_macros(7)):
Bestie, if you want log10f() and log10l() to even exist for you, you gotta unlock them with one of these β¨
log10f(), log10l():
_ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L
|| /* Since glibc 2.19: */ _DEFAULT_SOURCE
|| /* glibc <= 2.19: */ _BSD_SOURCE || _SVID_SOURCE
Like a vibe check but for the preprocessor. She will absolutely gatekeep you if you don't set these. π
π¦ DESCRIPTION π¦
These functions return the base-10 logarithm of x. That's it, that's the whole thing. Simple. Elegant. Main character energy. π
π RETURN VALUE π
On success, these functions return the base-10 logarithm of x. Slay. β¨
But for the special cases β and yes bestie that includes where x is 0, 1, negative, infinity, or NaN β go peek at log(3). She has the tea. β
π ERRORS π
Wanna know if an error even happened when you called these? Go read math_error(7), she explains how to check. π
And for the whole discussion of what errors can occur for these functions, see log(3). Nothing messy happens here that isn't already log's problem, ngl.
π ATTRIBUTES π
For an explanation of the terms used in this section, see attributes(7).
- Interface:
log10(),log10f(),log10l()- Attribute: Thread safety
- Value:
MT-Safe
MT-Safe meaning she's safe to use across threads β no drama, no chaos, just vibes. π
π STANDARDS π
C11, POSIX.1-2008. Certified. Periodt. π
π HISTORY π
C99, POSIX.1-2001.
The variant returning double also conforms to SVr4, 4.3BSD, C89. She's been around, bestie β a true legend of the game, aging like fine wine. π
π SEE ALSO π
The whole logarithm friend group honestly. Go say hi. π¦
And that's the page, bestie!! This little masterpiece is from Linux man-pages 6.20, dated 2026-02-08, and she ate and left absolutely no crumbs π β¨πΈπ
π¦ where this page comes from
- arch rolling: man-pages 6.20-1 Β· BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
- nixpkgs unstable: man-pages 6.20
- π the page's license: Linux-man-pages-copyleft
- Copyright 1993, David Metcalfe <david@prism.demon.co.uk>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms