The Arithmetic Operators are:

+ Addition
– Subtraction
* Multiplication
/ Division
% Modulus

The division operator (“/”) returns a float value anytime,even if the two operands are integers (or strings that get converted

Example:
Code:

$a=7;
$b=5;
echo $c=$a+$b."
"; echo $d=$a-$b."
"; echo $e=$a*$b."
"; echo $f=$a/$b."
"; echo $g=$a%$b;

Output:

12
2
35
1.4
2

eXTReMe Tracker