Round Function

Round Function
All Functions

Summary

Returns the nearest integer to the number n.

Syntax

How to use

The round function returns the nearest integer to a number. When the fractional part is exactly 0.5, the function typically rounds up. For example, the round of returns the integer , while the round of returns .

 round(6.28) = 6
 round(6.5) = 7

Examples

 round(1.3) = 1
 round(1.7) = 2
 round(0.8) = 1
 round(7.813) = 8
 round(16.21) = 16
 round(5.0) = 5

Related Functions

Returns the integer part of the number n.

Returns the least integer greater than or equal to the number n.