名称:/ (divide)
例子:
int g = 50 / 5; // Assigns 10 to ‘g’
int h = g / 5; // Assigns 2 to ‘h’
描述:
Divides the value of the first parameter by the value of the second parameter. The answer to the equation 20 / 4 is 5. The number 20 is the sum of four occurences of the number 5. As an equation we see that 5 + 5 + 5 + 5 = 20.
将第一个参数的值除以第二个参数的值。 方程20/4的答案为5。数字20是数字5的四次累加之和。如方程:5 + 5 + 5 + 5 = 20。
语法:
value1 / value2
参数:
value1 | int or float |
---|---|
value2 | int or float, but not zero (it is not possible divide by zero) 非零 |
相关:
- 本文固定链接: http://iprocessing.cn/2017/07/21/divide-除/
- 转载请注明: Hewes 于 Processing编程艺术 发表
Pingback 引用通告: * (multiply) 乘 | Processing编程艺术
Pingback 引用通告: % (modulo) 模数 | Processing编程艺术