I can't think of the exact syntax at the minute but something like; if $# => 4 then for i = 1 to ($# - 4) echo "arg number $i is $expr($i)" next fi $# is the number of args passed so just pass the total number of args minus four ($~-4) That syntax is all wrong, but somebody on this list (in fact many people on this list) knows the correct syntax, thats just my crapp pesudo code to explain one method of achieving you desired result, HTH. James ;) -----BEGIN GEEK CODE BLOCK----- Version: 3.1 GIT/MU/U dpu s: a--> C++>$ U+> L++> B-> P+> E?> W+++>$ N K W++ O M++>$ V- PS+++ PE++ Y+ PGP t 5 X+ R- tv+ b+> DI D+++ G+ e(+++++) h--(++) r++ z++ ------END GEEK CODE BLOCK------ _______________________________________________ CentOS mailing list CentOS@xxxxxxxxxx http://lists.centos.org/mailman/listinfo/centos