Hello:
I am a very new Newbie. This is not a homework question.
The assignment question was actually on the use of the 2 different inputs 'read' and 'cat' ... that I know and turned in an hour ago. I don't need help with that. My question, like I said, probably sounds really dumb to most of you!!! It is no problem if you feel uncomfortable answering, but like I told you the homework question, I answered. It is my curiosity that is driving me crazy on a Saturday night and I am impatience...
I am just wondering why you would want to redirect the output from 'echo' and then do it again for 'cat'. It seems pointless; I am missing something somewhere... Does it even matter in this example? Am I reading too much into it?
# Append the contents of the Environment Variable called "${variable_name}"
# to the file called "${file}"
variable_name="the text I want to append"
echo "${variable_name}" >> ${file}
# Append the contents of the file called "${the_other_file}"
# to the the file called "${file}".
the_other_file="the_name_of_the_other_file"
cat "${the_other_file}" >> ${file}