subroutine splitStr(inStr, outStrAry) character(*), intent(in) :: inStr character(*), pointer :: outStrAry(:) ! intent(out) end subroutine splitStr
This “splits” the given string with the delimeter of consecutive spaces into an array, and returns it as the pointer character array.
outStrAry should not be initialised before the call. NOTE make sure to deallocate outStrAry(:) after the call.