I got one error in the first expr
nmin =$(expr ($nr-1)*31)
nmax =$(expr ($nr*31)-1)
array=`ls *d03_*` # specify files to be subsetted
for name in ${array[@]:nmin:30}
After reading the documentation seems like one space or really minor thing is creating the error
Also i don t know is the slicing in for is correct .
An array definition needs round parenthesis.
This assigns a string to the variable
x
:This assigns two values to an array: