integer

Pragma that tells the compiler to use integer operations from here to the end of the enclosing block. Improves processing time on systems without floating-point hardware support.

use integer;

$x = 10/3;   # $x is now 3, not 3.33333333333333333

Use the no integer directive to turn off integer inside an inner block.

Get Perl in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.