How to use log10 function in C

1 Answer

0 votes
#include <stdio.h>
#include <math.h>

int main () {
   int x = 10000;

   double l10 = log10(x);

   printf("%lf\n", l10);

   return(0);
}



/*
run:

4.000000

*/

 



answered Jun 19, 2021 by avibootz

Related questions

2 answers 116 views
116 views asked May 29, 2022 by avibootz
1 answer 309 views
1 answer 145 views
145 views asked Jun 6, 2020 by avibootz
1 answer 148 views
148 views asked Jun 5, 2020 by avibootz
...