Skip to main content

exact_int

No overview available.

def exact_int(
value: Union[int, float, str]
) - > int

Converts a numeric value to an integer, ensuring that the conversion does not result in any loss of precision.

Parameters

NameTypeDescription
valueUnion[int, float, str]The numeric value or string representation to be converted into an exact integer.

Returns

TypeDescription
intThe integer representation of the input value.