ADJUSTR— Right adjust a string
ADJUSTR(STRING) will right adjust a string by removing trailing spaces.
Spaces are inserted at the start of the string as needed.
Fortran 95 and later
RESULT = ADJUSTR(STRING)
|STR||The type shall be |
The return value is of type
CHARACTER and of the same kind as
STRING where trailing spaces are removed and the same number of
spaces are inserted at the start of STRING.
program test_adjustr character(len=20) :: str = 'gfortran' str = adjustr(str) print *, str end program test_adjustr