Operators in PHP
Operators are used to perform operations on variables and values. PHP supports different types of operators such as arithmetic, comparison, logical, and assignment operators.
Example:
perl
$x = 5;
$y = 2;
$sum = $x + $y; // addition
$product = $x * $y; // multiplication
$greater_than = $x > $y; // comparison
No comments:
Post a Comment