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


/* real constants and functions, in JSI */
var x, y;
 
;Math.E;
;Math.PI;
 
;x = 100.0;
;Math.sqrt(x);
;Math.log(x);
 
;x = 2.0;
;Math.exp(x);
 
;x = -x;
;Math.abs(x);
 
;x = 42.42;
;Math.floor(x);
;Math.ceil(x);
 
;x = 10.0;
;y = 5;
;Math.pow(x,y);
 
/*
=!EXPECTSTART!=
Math.E ==> 2.718281828459045
Math.PI ==> 3.141592653589793
x = 100.0 ==> 100
Math.sqrt(x) ==> 10
Math.log(x) ==> 4.605170185988092
x = 2.0 ==> 2
Math.exp(x) ==> 7.38905609893065
x = -x ==> -2
Math.abs(x) ==> 2
x = 42.42 ==> 42.42
Math.floor(x) ==> 42
Math.ceil(x) ==> 43
x = 10.0 ==> 10
y = 5 ==> 5
Math.pow(x,y) ==> 100000
=!EXPECTEND!=
*/