Vague / Wrong Instructions

Screen Link:

The first prompt on “Redirecting output with >>” states:
“Append the first row of any of the files in rg_data to a new file called math_dataset in your home directory.”
The answer to this prompt is: head -n 1 /home/dq/rg_data/Computers\ &\ Mathematics >>math_dataset

I’d say the prompt is vague and/or incorrect. It should read:
“Append the first row of any of the files in rg_data/Computers\ \&\ Mathematics to a new file called math_dataset in your home directory.”

I actually followed the prompt as literally written, and it came back as incorrect.

4 Likes

@ncollin1985: I think what they meant was you can pick any file from the list as mentioned here.

1 Like

My instinct was this:

/home/dq$ head -n 1 /home/dq/rg_data/* >>/home/dq/math_dataset

but it was incorrect as well

I guess I misunderstood ‘any’ files with ‘all’ files. Although I suppose ‘any’ could be ‘all’?

3 Likes

@gosaints: any means 1 of out the many files in the directory.

1 Like