Microsoft Word - Core PHP Programming Using PHP to Build Dynamic Web Sites

(singke) #1

print(hexdec("0x7FAD"));
print("
\n");
?>


double log(double value)


The log function returns the natural logarithm of the value argument.


<?
//prints 3.0022112396517
print(log(20.13));
?>


double log10(double value)


The log10 function returns the decimal logarithm of its argument.


<?
//prints 3.2494429614426
print(log10(1776));
?>


integer octdec(string octal_number)


The octdec function returns the integer value of a string representing an octal number.


<?
//prints 497
print(octdec("761"));
?>


double pi()


The pi function returns the approximate value of pi. Alternatively, you may use the M_PI
constant.


<?
//prints 3.1415926535898
print(pi(). "
\n");

Free download pdf