3.4.3.3 Number
Numeric instructions provide a comprehensive set of core functions for numerical computation and operations, covering the entire workflow from basic mathematical operations to advanced numerical processing.
| Blocks | Note |
 | Numeric value; you can enter a numeric value. |
 | Convert the number to a different data type. It can be converted to an integer or a floating-point number. |
 | Returns a constant. Available constants include: π: the mathematical constant π (pi), 3.141592653589793. e: Euler's number (2.7182...) φ: Golden ratio, 1.618033988749894848204586834... sqrt(2): Returns the square root of 2 sqrt(2): Returns the square root of 0.5 inf: Returns a positive infinite floating-point number. |
 | Determine the type of this number. The available options are: even, odd, integer, positive, and negative. |
 | Perform common advanced mathematical operations on numerical values, such as taking the absolute value, rounding down, rounding up, calculating square roots, and evaluating sine, cosine, and tangent functions. |
 | Rounds a number to a specified number of decimal places. Parameter 1: Numeric expression Parameter 2: Number of decimal places. |
 | Mathematical operations on lists, including sum, minimum, maximum, median, and more. |
 | Returns a random decimal number. |
 | Generate any integer or decimal within a specified range; by default, it generates a random integer between 1 and 10. |
 | Modulo operation. |
 | Floor division. |
 | Perform a mapping operation on the values to map the values in one range to the values in another range on a one-to-one basis. |
 | Constrain the values so that the output does not exceed the maximum or fall below the minimum. |