User Tools

Site Tools


en:arithmeticoperators

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

en:arithmeticoperators [2016/08/09 17:03]
admin created
en:arithmeticoperators [2016/08/09 17:11] (current)
admin [Arithmetic Operators]
Line 5: Line 5:
 ^Arithmetic Operators^^^^ ^Arithmetic Operators^^^^
 ^Operator^Name^Example^Comments^ ^Operator^Name^Example^Comments^
-|+|Addition|a + b|add two numeric values. ​ If both are an integer, then the result will be an integer. ​ If one or both are floating point numbers then the result will be floating point. ​ If one or both values are strings the plus operator will concatenate the strings.<​sup>​2</​sup>​| +|+|Addition|a + b|Add two numeric values. ​ If both are an integer, then the result will be an integer. ​ If one or both are floating point numbers then the result will be floating point. ​ If one or both values are strings the plus operator will concatenate the strings.<​sup>​2</​sup>​| 
-|-|Subtraction|a - b|subtract ​two numeric values| +|-|Subtraction|a - b|Subtract ​two numeric values.  If both were integer and the operation did not overflow then an integer will be returned else a floating point number will be the result.
-|*|Multiplication|a * b| | +|*|Multiplication|a * b|Multiply the two numbers. ​  If both were integer and the operation did not overflow then an integer will be returned else a floating point number will be the result. ​
-|/​|Division|a / b|Returns a decimal ​number of times that b goes into a.|+|/​|Division|a / b|Returns a floating point number of times that b goes into a.|
 |\|Integer Division|a \ b|Returns the number of whole times that b goes into a.| |\|Integer Division|a \ b|Returns the number of whole times that b goes into a.|
 |%|Modulo|a % b|Returns the remainder of the integer division of a and b.| |%|Modulo|a % b|Returns the remainder of the integer division of a and b.|
-|%%++%%|Increment Prefix|%%++a%%|Increment (add one) the the variable and return the value after the increment. (may be applied ONLY to numeric variables or array elements) ​ <​sup>​1</​sup>​| +
-|%%++%%|Increment Suffix|%%a++%%|Return the value of the variable and then increment the variable by one for the next time it is accessed. (may be applied ONLY to numeric variables or array elements) <​sup>​1</​sup>​| +
-|--|Decrement Prefix|--a|Decrement (subtract one) the the variable and return the value after the decrement. (may be applied ONLY to numeric variables or array elements) <​sup>​1</​sup>​| +
-|--|Decrrement Suffix|a--|Return the value of the variable and then decrement the variable by one for the next time it is accessed. (may be applied ONLY to numeric variables or array elements) <​sup>​1</​sup>​| +
-\\+
en/arithmeticoperators.txt · Last modified: 2016/08/09 17:11 by admin