Quantcast
Channel: Intel® Software - Intel® Visual Fortran Compiler for Windows*
Viewing all articles
Browse latest Browse all 5691

Transfering string sequence to integer array

$
0
0

I want to be able to transter a sequence of numbers in a string to an array.

My question is what will be the most intuitive way to behave when the number

of elements in s are different from size of isq 

 

Integer, Allocatable :: isq(:)
Call split ( "2/3/5", "/", isq )

subroutine split (s,delim,isq)
  Character (len=*) :: s
  Character (len=1) :: delim
  Integer :: isq

end subroutine

 


Viewing all articles
Browse latest Browse all 5691

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>