please pardon since I am a UNIX beginner.
I wanna write a shell script that can ask user type in the filename and output the number of lines in that file, here is my code:
echo "Pls enter your filename:"
read filename
result=wc -l $filename
echo "Your file has $result lines"
However, I couldn't get it working since it complains about the identifier "filename". Could experts help?Thanks !!