arrays !!!

Go down

arrays !!!

Post by Abhiramy on Thu Mar 04, 2010 7:10 pm

wat is the cmnd used to dynamically insert elements in an array???

Abhiramy

Posts : 9
Points : 21
Join date : 2010-02-26

View user profile

Back to top Go down

to get and display array elements

Post by aarthi on Tue Mar 09, 2010 2:24 pm

this is an example for getting elements for an array dynamically and displaying it
echo "enter length"
read n
for (( i=0;i<n;i++ ))
do
read a[i]
done
echo "elemnts are:"
echo ${a[@]}

aarthi

Posts : 12
Points : 22
Join date : 2010-02-26

View user profile

Back to top Go down

Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum