You are viewing content for 5.1 | 5.0 | 4.9 | 4.8 | 4.7 | 4.6 | 4.5 | 4.4 | 4.3 | Previous Releases


round

Returns the closest integer to its floating point argument.

Example

Find the closest integer to 56.10145.

round(56.10145)

In this example, 56 is returned.

Find the closest integer to 0.6724.

round(0.6724)

This example evaluates to 1.

Syntax

round(double expr x)
  • x : expression evaluating to double

Returns

long

Notes

round() returns the closest integer to its double argument.


© Incorta, Inc. All Rights Reserved.