Hi All,

I want to pass few dynamic arguments to shell script. The number of arguments differ each time I call the script.

I want to print the arguments using the for loop as below. But not working out.

for (( i=1; i<=$#; i++ ))
do
echo $"($i)"
done

/bin/sh test.sh arg1 arg2 arg3

Any one please help.

Please don't double post. We will see your first post and reply there, there is no need to post the same question twice in a row.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.