Round
See
Returns the number rounded up by the specified number.
Syntax
Round(Number,Num_digits)
Number.
The number of digits specified by num_digits.
Description
- If num_digits is greater than 0, it is rounded to the specified decimal place.
- If num_digits is equal to 0, it is rounded to the nearest integer.
- If num_digits is less than 0, it is rounded to the left of the decimal point.
Example
Formula -------------------------------------------- description (result)
Round (2.15, 1) ---------------------------- round 2.15 To a decimal place (2.2)
Round (2.149, 1) -------------------------- round 2.149 to a decimal place (2.1)
Round (-1.475, 2) -------------------------- round-1.475 to two decimal places (-1.48)
Round (21.5,-1) ----------------------------- round 21.5 to the left of the decimal point (20)
Roundup
See
Move away from the zero value and round up the number.
Syntax
Roundup(Number,Num_digits)
Number is any real number to be rounded up.
The number of digits after num_digits rounding.
Description
- The roundup function is similar to the round function. The difference is that the roundup function always rounds up a number.
If num_digits is greater than 0, it is rounded up to the specified decimal place.
If num_digits is equal to 0, it is rounded up to the nearest integer.
If num_digits is less than 0, it is rounded up on the left of the decimal point.
Example
Formula --------------------------------------------- description (result)
Roundup (3.2, 0) ------------------------------ round up 3.2, decimal place is 0 (4)
Roundup (76.9, 0) -------------------------- round up 76.9, decimal point is 0 (77)
Roundup (3.14159, 3) ----------------------- round up 3.14159, retain three decimal places (3.142)
Roundup (-3.14159, 1) -------------------- round-3.14159 up and keep a decimal (-3.2)
Roundup (31415.92654,-2) ---------------- round up 31415.92654 to two places (31500) on the left of the decimal point)