Images

Working with Arithmetic Operators

Images To view the accompanying video for this lesson, please visit mhprofessional.com/nixonphp/.

In the previous lesson, you saw a few examples of operators in action, such as the + operator used for addition, the . operator for concatenating strings together, the – operator used for subtraction, and the = operator used for assigning values.

   But PHP supports many more operators than that, such as *, /, and more. It also includes functions you can draw on for more advanced expression evaluation, such as sin(), sqrt() ...

Get PHP: 20 Lessons to Successful Web Development now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.