Agreed. There are too many scripting errors to work out what the script is meant to do.
For example:
Line 1 should be deleted. Overwriting $PATH will stop external commands working.
Line 4 should be deleted. (The "read" on line 3 already read the enter).
This sequence of lines makes no sense and gives syntax errors:
Quote:
while [ $a -lt $n ]
do
a=$[a+1]
read m$a
read enter
done