Task

Show how to use the following math constants and functions in your language   (if not available, note it):

   e   (base of the natural logarithm)
   



π


{\displaystyle \pi }


   square root
   logarithm   (any base allowed)
   exponential   (ex )
   absolute value   (a.k.a. "magnitude")
   floor   (largest integer less than or equal to this number--not the same as truncate or int)
   ceiling   (smallest integer not less than this number--not the same as round up)
   power   (xy )


Related task

   Trigonometric Functions


e = exp(1)                       # e  not available
print "e     = "; e
print "PI    = "; PI
 
x = 12.345
y = 1.23
 
print "sqrt  = "; sqr(x)         # square root
print "ln    = "; log(e)         # natural logarithm base e
print "log10 = "; log10(e)       # base 10 logarithm
print "log   = "; log(x)/log(y)	 # arbitrary base logarithm
print "exp   = "; exp(e)         # exponential
print "abs   = "; abs(-1)        # absolute value
print "floor = "; floor(-e)      # floor
print "ceil  = "; ceil(-e)       # ceiling
print "power = "; x ^ y          # power