Answers for "how to use log base e in c++"

C++
6

log base c++

int intlog(double base, double x) {
    return (int)(log(x) / log(base));
}
Posted by: Guest on September-14-2020
7

log base e synthax c++

#include <math.h>       /* log */

 double param, result;
  param = 10;
  result = log (param);
  printf ("log(%f) = %f\n", param, result );
Posted by: Guest on June-09-2020

Browse Popular Code Answers by Language