9.5 ACHAR — Character in ASCII collating sequence
- Description:
-
ACHAR(I)
returns the character located at positionI
in the ASCII collating sequence. - Standard:
-
Fortran 77 and later, with KIND argument Fortran 2003 and later
- Class:
-
Elemental function
- Syntax:
-
RESULT = ACHAR(I [, KIND])
- Arguments:
-
I The type shall be INTEGER
.KIND (Optional) An INTEGER
initialization expression indicating the kind parameter of the result. - Return value:
-
The return value is of type
CHARACTER
with a length of one. If the KIND argument is present, the return value is of the specified kind and of the default kind otherwise. - Example:
-
program test_achar character c c = achar(32) end program test_achar
- Note:
-
See ICHAR for a discussion of converting between numerical values and formatted string representations.
- See also:
© Free Software Foundation
Licensed under the GNU Free Documentation License, Version 1.3.
https://gcc.gnu.org/onlinedocs/gcc-11.1.0/gfortran/ACHAR.html