Blocks
keyboard_arrow_up
Add
Math
Index
-
- Basic number block
- Logical operators ( =, ≠, >, < ...)
- Arithmetic Operators ( + , -, *, / ...)
- Random integer
- Random Fraction
- Random set seed to
- Min / Max
- Square root
- Absolute value
- Neg
- Log
- e^
- Round
- Floor
- Ceiling
- Modulo
- Remainder
- Quotient
- Trigonometric Values
- Convert Radians <> Degrees
- Format as a decimal
- Is a number? Is it base 10?
- Convert number
-
Math Blocks
Some blocks contain drop-down, the option you are looking for may be in them.
- Basic number block
- It can be used as any positive or negative number (decimals included). By double clicking on the '0' we can edit its content.
- Logical operators ( =, ≠, >, < ...)
- These signs will allow us to compare numbers.
- Check if two numbers are the same and return true or false.
- Check if two numbers are not equal and return true or false.
- Check if the first number is greater than the second number and return true or false.
- Check if the first number is greater than or equal to the second number and return true or false.
- Check if the first number is less than the second number and return true or false.
- Check if the first number is less than or equal to the second number and return true or false.
- Arithmetic Operators ( +, -, *, / ...)
- These signs will allow us to perform operations with numbers.
- Returns the result of adding any number of blocks that have a numerical value together. Blocks with a numerical value include the basic numeric block, the length of the list or text, the variables with a numerical value, etc.
- This block is a mutator and can be expanded to allow more numbers in the sum, as many as we want.
- Returns the result of subtracting the second number from the first.
- Returns the result of multiplying any number of blocks that have a numerical value together.
- Returns the result of dividing the first number by the second.
- Check if the first number is greater than or equal to the second number and return true or false.
- Returns the result of the first number raised to the power of the second.
- Random integer
- Returns a random integer value between the given values, inclusive. The order of the arguments does not matter.
- Random Fraction
- Returns a random value between 0 and 1.
- Random seed
- Use this block to generate repeatable sequences of random numbers. You can generate the same sequence of random numbers by first calling the random set seed with the same value. This is useful for testing programs that involve random values.
- Min / Max
- In the case of Min , it returns the smallest value in a set of numbers. If there are slots unplugged in the block, min will also consider 0 in its set of numbers. This block is a mutator and a drop-down menu.
- In the case of Max , it returns the largest value in a set of numbers. If there are slots unplugged in the block, max will also consider 0 in its set of numbers. This block is a mutator and a drop-down menu.
- Square root
- Returns the square root of the given number.
- Absolute value
- Returns the absolute value of the given number.
- Neg
- Returns the negative of a given number.
- Log
- Returns the natural logarithm of a given number, that is, the logarithm of the base e (2.71828 ...).
- e^
- Returns e (2.71828 ...) raised to the power of the given number.
- Round
- Returns the given number rounded to the nearest integer. If the fractional part is <.5, it will be rounded down, if it is> .5 it will be rounded to above. If it is exactly equal to .5, the numbers with a whole pair part will be rounded down, and the numbers with a Odd whole part will be rounded up. (This method is called round to even).
- Floor
- Returns the smallest integer that is greater than or equal to the given number.
- Ceiling
- Returns the largest integer that is less than or equal to the given number.
- Modulo
- Module (a, b) is the same as remainder (a, b) when a and b are positive. Of more general way, module (a, b) is defined for any a and b so that (Lower (a / b) × b) + module (a, b) = a. For example, module (11, 5) = 1, module (-11, 5) = 4, module (11, -5) = -4, module (-11, -5) = -1. Module (a, b) always has the same sign as b, while the rest (a, b) always has the same sign as a.
- Remainded
- The remainded (a, b) returns the result of dividing a and b. The rest is the fractional part of the result multiplied by b.
- For example, the remainded (11.5) = 1 because 11/5 = 2 1/5, in this case, 1/5 is the part
fractional. We multiply this by b, in this case 5 and we get 1, our remainded.
Another example is the remainded of (-11, 5) = -1, the rest (11, -5) = 1 and the remainded (-11, -5) = -1.
- Quotient
- Returns the result of dividing the first number by the second and discard any fractional part of the result.
- Trigonometric Values
- Returns the cosine of the given number in degrees.
- Returns the sine of the given number in degrees.
- Returns the tangent of the given number in degrees.
- Returns the arccosine of the given number in degrees.
- Returns the arcsine of the given number in degrees.
- Returns the arctangent of the given number in degrees.
- Returns the arctangent of y / x, given y and x.
- Conversion Grades <> Radians
- Radians-Degrees, returns the value in degrees of the number given in radians. The result will be an angle in the range [0, 360).
- Degrees-Radians, returns the value in radians of the number given in degrees. The result will be an angle in the range [-π, + π).
- Format as a decimal
- Format a number as a decimal with a given number of decimals after the decimal point. The number of decimals must be a non-negative integer. The result is produced by rounding the number (if there were too many decimals) or by adding zeros to the right (if there were very few).
- It's a number? Is it base 10?
- Returns true if the given object is a number, and false of the contrary. The same happens for the options: is it base 10?, is it hexadecimal?, is it binary?.
- Convert number
- Take a string of text that represents a positive integer in a base and returns a string that represents the same number is another base.
- For example, if the input string is 10, then the conversion from base 10 to binary will produce the string 1010, while if the input string is the same 10, then the binary to base 10 conversion will produce the string 2.
- If the input string is the same 10, then the conversion from base 10 to hex will produce the A chain