---
url: /flow/guide/scripting-reference/functions/numeric/int.md
---

# Int

## Declaration

`function Int(const X: Extended): Extended`

### Example

```pascal
procedure OnMapEvent(var Value:Variant);
begin
  Value := Int(123.45); //result is 123
end;
```

## Description

Retuns the Integer portion of a decimal number. This is very similar to [Trunc](/flow/guide/scripting-reference/functions/numeric/trunc) however the result is still a [Float (Double, Extended, Currency)](/flow/guide/scripting-reference/data-types/float) data type rather than an [Integer (Integer, Cardinal, Int64)](/flow/guide/scripting-reference/data-types/integer) data type.

Refer to [Frac](/flow/guide/scripting-reference/functions/numeric/frac) for a function that returns the fractional part of a decimal number
