next up previous contents
Next: Simple Input / Output Up: Expressions and Assignment Previous: Intrinsic Logical Operations

 

Intrinsic Character Operations

Consider,

   CHARACTER(LEN=*), PARAMETER :: str1 = "abcdef"
   CHARACTER(LEN=*), PARAMETER :: str2 = "xyz"

substrings can be taken,

The concatenation operator, //, is used to join two strings.

   PRINT*, str1//str2
   PRINT*, str1(4:5)//str2(1:2)

would produce

   abcdefxyz
   dexy

For more information, click here gif


next up previous contents
Next: Simple Input / Output Up: Expressions and Assignment Previous: Intrinsic Logical Operations

©University of Liverpool, 1997
Wed May 28 23:37:18 BST 1997
Not for commercial use.