here is a sample code
astr[10]=a
astr[20]=b
astr[30]=b
astrR="astr[@]"
echo ${!astr[@]} #the indexes
echo ${!astrR} #the values
#FAIL: echo ${!!astrR}
astrR="!astr[@]" # wild guess
echo ${!astrR} # empty output, so I am still wild
So, how to get the indexes using astrR ?
astrR? Are you trying to print indices and values of the associative array?bashis not supported directly. You might need to re-consider your design if you are planning to do this bash