8.3.1.1 I Field Descriptor

The I field descriptor transfers decimal integer values. It takes the following form:

Iw[.m]

The corresponding I/O list element must have an integer or logical data type.

Input Processing

In an input statement, the I field descriptor transfers w characters from the external field and assigns them to the corresponding I/O list element as an integer value. The external data must have the form of an integer constant. It cannot contain a decimal point or exponent field.

The I field descriptor processes input in the following ways:

The following list illustrates valid input processing with the I field descriptor (the symbol ^ represents a nonprinting space character):

Format    External Field       Internal Value
I4        2788                 2788
I3        -26                   -26
I9        ^^^^^^312             312

Output Processing

In an output statement, the I field descriptor transfers the value of the corresponding I/O list element, right-justified, to an external field that is w characters long.

The I field descriptor processes output in the following ways:

The following list illustrates valid output processing with the I field descriptor (the symbol ^ represents a nonprinting space character):

Format     Internal Value       External Representation
I3          284                 284
I4         -284                 -284
I4            0                 ^^^0
I5          174                 ^^174
I2         3244                 **
I3         -473                 ***
I7           29.812             An error; the decimal point is invalid
I4.0          0                 ^^^^
I4.2          1                 ^^01
I4.4          1                 0001


Previous Page Next Page Table of Contents