User control passing parameter

there is a example:
sh shell

name () {
echo $1
echo $2
echo $3
}

echo "Enter value:"
read a b c d
name $a $b

here permit user enter 1-4 value to the variables respectively, question is : no restrict for user input...?
using only 1 variable to yield all user input?

anyone can help?

Sorry but I'm having a bit of trouble understanding your problem....can you rephrase it....

We are focsing on the question:

Q1. user was asked for input data or value, so that user can enter any number of data or value like: 1 4 a 45 23 ... then pass those values to the function?

Q2. the above script show in the way to limit 4 values input, can 4 values using only 1 variable in which passing the value to the function only get $1 variable instead?

can u get me?

I'm not sure.....(This isn't homework is it?) I don't get what you mean with the 1-4 thing....but does this help at all ?

You can easily read in a list of characters from a promt as one variable... i.e.

Script is called my_script:

echo "enter a few strings"
read myinput
echo "This is the vairable called myinput that I have: $myinput"

Then when executed you have:

$ my_script
enter a few strings
a qwer 35 asf 45
This is the vairable called myinput that I have: a qwer 35 asf 45

Therefore multiple strings can be passsed into one variable. Basically the spaces are just characters within the string.