Which command will display the last line of the file foo.txt?
Suggested Answer: D
Get Premium LFCS Questions
as Interactive Web-Based Practice Test or PDF
Real Exam Format
Detailed Explanations
Instant Access
Get Your Practice Test
12 comments · newest first
KA
Kathrine
1 year ago
Yeah, tail is the way to go!
DE
Delpha
1 year ago
Wait, is last -n even a real command?
RA
Ranee
1 year ago
No way, I always use tail for this.
CH
Cherry
1 year ago
I thought it was B, but D is correct!
FE
Fernanda
1 year ago
It's definitely D, tail -n 1 shows the last line.
VE
Venita
1 year ago
I'm pretty sure "tail -n 1" is the correct answer. It seems like the most logical option for getting the last line of a file.
KA
Katlyn
1 year ago
I thought "last" was a command too, but I don't think it applies to files like this. I might be mixing it up with something else.
LE
Leeann
1 year ago
I remember practicing with "head" and "tail," but I can't recall which one specifically shows the last line. I feel like "tail" is the right choice.
MA
Marguerita
1 year ago
I think the command to show the last line is something with "tail," but I'm not sure if it's just "tail" or if it needs the "-n" option.
TE
Tequila
1 year ago
Hmm, I'm a bit unsure about this one. I can see the appeal of trying to build rapport with some humor, but that might come across as unprofessional. I think I'd lean towards just sticking with it and working through the language barrier, even if it gets frustrating.
CY
Cyril
1 year ago
I've got a good strategy for this. I'll eliminate the options I know are standard opinions, then choose the one that's left. Gotta love process of elimination!
GA
Galen
1 year ago
I'm not entirely sure about this one. The question seems a bit tricky, and I'm not familiar with the Decode function. I'll need to think it through carefully.