PHP numbers handle arithmetic for counts, totals, and measurements.

Numbers

numbers.php
<?php
$apples = ;
$oranges = 5;
$total = $apples + $oranges;
$average = $total / 2;

echo "apples=" . $apples . "\n";
echo "total=" . $total . "\n";
echo "average=" . $average . "\n";
<?php
$apples = ;
$oranges = 5;
$total = $apples + $oranges;
$average = $total / 2;

echo "apples=" . $apples . "\n";
echo "total=" . $total . "\n";
echo "average=" . $average . "\n";
<?php
$apples = ;
$oranges = 5;
$total = $apples + $oranges;
$average = $total / 2;

echo "apples=" . $apples . "\n";
echo "total=" . $total . "\n";
echo "average=" . $average . "\n";
arithmetic Number expressions combine values with operators such as `+`, `-`, `*`, and `/`.