On Thu, Apr 26, 2012 at 05:54:27PM +0200, Maarten Billemont wrote: > On 26 Apr 2012, at 01:18, Linda Walsh wrote: > > > > Ishtar:> echo "${b[*]}" > > You should always recommend the "${b[@]}" variant. "${b[*]}" is rarely > useful in the event that your intent is to merge the array into a single > string, eg. for displaying elements to a user: > dirs=(*/) > (IFS=,; echo "The dirs are: ${dirs[*]}") > > But anyway, that's an aside from this topic, which has very little to do with > this.
If the goal is to see the contents of an array, I'd use one of these, depending on how much detail I need: printf '<%s> ' "${array[@]}"; echo declare -p array