Next: , Previous: ADJUSTL, Up: Intrinsic Procedures


8.7 ADJUSTR — Right adjust a string

Description:
ADJUSTR(STR) will right adjust a string by removing trailing spaces. Spaces are inserted at the start of the string as needed.
Option:
f95, gnu
Class:
elemental function
Syntax:
STR = ADJUSTR(STR)
Arguments:

STR The type shall be CHARACTER.

Return value:
The return value is of type CHARACTER where trailing spaces are removed and the same number of spaces are inserted at the start of STR.
Example:
          program test_adjustr
            character(len=20) :: str = 'gfortran'
            str = adjustr(str)
            print *, str
          end program test_adjustr