Search code examples
c

How can you use Ln function in C programing?


Header file math.h is for mathematical functions like cos,sin, tan.. But how to write the ln function and not log?


Solution

  • The C function log is the natural logarithm, which mathematicians usually write as "ln".

    The C function log10 is the logarithm base 10, which is sometimes written "log".