#1 definition of variables
x <- 3; y <- 4; z <- 5
x; y; z
#2 four arithmetic operation
a <-(x+y)*z+(x-y)/z
a;
#3 square root & power
b1 <- sqrt(x); b2 <- x^0.5
b1; b2
#4 Pi & trigonometric functions
c <- pi/3
c1 <- sin(c); c2 <- cos(c); c3 <- tan(c)
pi; c1; c2; c3
#5 exponential and logarithmic functions
d <- exp(1)
d1 <- log(d)
d2 <- log10(d)
d; d1; d2
#6 absolute value & truncation
e <- -2.5
e1 <- abs(e)
e2 <- trunc(e)
e1; e2

