## [1] 3.321928
## [1] 1
## [1] 22026.47
## [1] 5
## [1] 4
Note that, it’s possible to use <- or = for variable assignments.
Note that, R is case-sensitive. This means that Price is different from price.
# height of a rectangle
height <- 10
# width of a rectangle
width <- 5
# area of rectangle
area <- height*width
area## [1] 50