R Arithmetic Operators

These operators are used to carry out mathematical operations like addition and multiplication. Here is a list of arithmetic operators available in R.

Arithmetic Operators in R

Operator

Description

+

Addition

Subtraction

*

Multiplication

/

Division

^

Exponent

%%

Modulus (Remainder from division)

%/%

Integer Division

Some examples are:

x = 5

y = 16

x+y

[1] 21

x-y

[1] -11

x*y

[1] 80

y/x

[1] 3.2

y%/%x

[1] 3

y%%x

[1] 1

y^x

[1] 1048576

Last updated

Was this helpful?