FORTRAN 77 Language Reference

Character Functions

Table 6-5 Character Functions

Intrinsic Function 

Definition 

No. of Args. 

Specific 

Names 

Argument Type 

Function Type 

Conversion See Note (5).

Conversion to character 

Conversion to integer 

See also:

Table 6-2.

1 

 

1 

CHAR ACHAR @ ICHAR IACHAR @ INTEGER CHARACTERCHARACTER INTEGER

Index of a substring 

Location of substring a2 in string a1  

See Note (10).

2 

INDEXCHARACTERINTEGER

Length 

Length of character entity  

See Note (11).

1 

LENCHARACTERINTEGER

Lexically greater than or equal  

a1 a2 

See Note (12).

2 

LGECHARACTERLOGICAL

Lexically greater than 

a1 > a2 

See Note (12).

2 

LGTCHARACTERLOGICAL

Lexically less than or equal  

a1 £ a2

See Note (12).

2 

LLECHARACTERLOGICAL

Lexically less than 

a1 < a2 

See Note (12).

2 

LLTCHARACTERLOGICAL

On an ASCII machine (including Sun systems):

On a non-ASCII machine, ACHAR and IACHAR were intended to provide a way to deal directly with ASCII.