Skip to main content

4.8) Exercise 4: Solution


From the home directory copy the file into the research directory by:
cp data1 research
Now you need to move into the research directory to issue the next command so:
cd research
to go into that directory. Now use:
cp data1 documents
Then:
cd documents
ls
to check the file ‘data1’ is there.
Tip
If you have two or more files, say data1 and data2, and you want to copy them into the documents directory then list the files and just make sure the directory is listed last.   For example,
cp data1 data2 documents