ADJUSTR(3I) Last changed: 2-5-98
NAME
ADJUSTR - Adjusts a character string to the right
SYNOPSIS
ADJUSTR ([STRING=]string)
IMPLEMENTATION
UNICOS, UNICOS/mk, and IRIX systems
STANDARDS
Fortran 90
DESCRIPTION
The ADJUSTR intrinsic function adjusts a character string to the
right, removes trailing blanks, and inserts leading blanks. It
accepts the following argument:
string Must be of type character
ADJUSTR is an elemental function. The name of this intrinsic cannot
be passed as an argument.
RETURN VALUES
The result is type character with the same length as string.
The value of the result is the same as string except that any trailing
blanks have been deleted and the same number of leading blanks have
been inserted.
EXAMPLES
In the following examples, a carat (^) indicates a blank.
Example 1:
VAR = ADJUSTR( 'WORD^^' )
PRINT *,"VAR='", VAR,"'"
This code segment returns the following output:
VAR='^^WORD'
Example 2:
CHARACTER*29 STRING
STRING = '^^^TEST STRING FOR ADJUSTR^^^'
WRITE(6,1) '>', STRING,'<'
WRITE(6,1) '>', ADJUSTR(STRING), '<'
1 FORMAT(3A)
END
This code returns the following output:
>^^^TEST STRING FOR ADJUSTR^^^<
>^^^^^^TEST STRING FOR ADJUSTR<
SEE ALSO
Intrinsic Procedures Reference Manual, publication SR-2138, for the
printed version of this man page.