exam questions

Exam 010-160 All Questions

View all questions & answers for the 010-160 exam

Exam 010-160 topic 1 question 59 discussion

Actual exam question from LPI's 010-160
Question #: 59
Topic #: 1
[All 010-160 Questions]

Which of the following commands output the content of the file Texts 2.txt? (Choose two.)

  • A. cat 'Texts 2.txt'
  • B. cat -- Texts 2.txt
  • C. cat |Texts 2.txt|
  • D. cat 'Texts\ 2.txt'
  • E. cat Texts\ 2.txt
Show Suggested Answer Hide Answer
Suggested Answer: AE 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
oe_albornoz
Highly Voted 3 years, 6 months ago
The correct answers are AE
upvoted 17 times
Keona
3 years, 5 months ago
I don't think its E. there is the \ in that answer. on the command it just says Texts 2.txt
upvoted 2 times
MIU
3 years, 2 months ago
Did you really try the command????? Don't think, just try. B doesn't work. Only A and E work.
upvoted 3 times
d0ggyl0v3r
3 years ago
in ubuntu cat -- Texts 2.txt does in fact work!! i just did it
upvoted 3 times
...
...
bren_
3 years, 4 months ago
bren@QUAKE:~/LPI$ touch "test 2" bren@QUAKE:~/LPI$ echo bla > "test 2" bren@QUAKE:~/LPI$ ll -h "test 2" -rw-r--r-- 1 bren bren 4 Sep 3 16:26 'test 2' bren@QUAKE:~/LPI$ cat "test 2" bla bren@QUAKE:~/LPI$ cat test\ 2 bla
upvoted 3 times
...
...
...
Praxisk
Highly Voted 3 years, 5 months ago
The correct answers are A and E. A is correct because it uses single quotes to create a literal string, and cat takes the argument as a single file instead of a list of files. B is incorrect. The -- option prevents anything after it from being interpreted as an option, but does not escape the space and cat will still interpret the argument as two files instead of one. E is correct because \ escapes the space character, so Texts\ 2.txt is interpreted as a single file.
upvoted 14 times
...
av4871
Most Recent 4 months, 3 weeks ago
Ubunto - ABE. Seems not two answer
upvoted 1 times
...
clecorre
9 months, 1 week ago
In fact E shoud be displayed as (ctrl v and ctrl j do go to a new line after the slash): cat Texts\ 2.txt
upvoted 1 times
...
hughesd010
1 year, 5 months ago
Selected Answer: AE
Tested on both Debian11 and Fedora36. The commands listed in "B" and "D" will fail. The commands listed in "A" and "E" will succeed. Like other similar questions, does examtopics review, research and update these questions? Given the age of these posts It is looking unlikely. Just, paid for a contributor membership for this test and am starting to question it.
upvoted 2 times
...
JamiB1979
1 year, 6 months ago
Selected Answer: AE
Tried A and E in my red hat box. Confirmed working
upvoted 1 times
...
shosha
1 year, 12 months ago
Selected Answer: AE
The correct answers are A & E.
upvoted 1 times
...
Pitmaster
2 years, 3 months ago
AE Who claimes other is lying or didn't try it.
upvoted 1 times
...
JRossJ
2 years, 4 months ago
I tested this on my Ubuntu Linux machine today 9/3/2021 and it is 100% confirmed that ALL 3 of the answers are correct, A+B+E. This is on Ubuntu Linux.
upvoted 3 times
...
Traian
2 years, 4 months ago
tested myself. A and E are correct
upvoted 1 times
...
combo10
2 years, 4 months ago
The correct answers are A and B cat 'Texts 2.txt' and cat -- Texts 2.txt
upvoted 1 times
...
smina
2 years, 8 months ago
root@kali:~# touch Texts2.txt root@kali:~# echo hello > Texts2.txt root@kali:~# cat Texts2.txt hello root@kali:~# cat 'Texts2.txt' hello root@kali:~# cat Texts\2.txt hello root@kali:~# cat -Texts\2.txt cat: opción inválida -- 'x' Pruebe 'cat --help' para más información. root@kali:~# cat |Texts2.txt| > ^C root@kali:~# cat 'Texts\2.txt' cat: 'Texts\2.txt': No existe el fichero o el directorio
upvoted 1 times
...
4ltmind
2 years, 8 months ago
A and B, test it on your terminal first.
upvoted 1 times
...
Emuti
2 years, 8 months ago
A and E are the correct answer
upvoted 2 times
...
MrBlood
2 years, 9 months ago
The correct answers are AE. Fix it.
upvoted 2 times
...
sgtloon
2 years, 10 months ago
It's A&E This is even explained in the CBTNugget course by Shawn Powers
upvoted 3 times
...
Allan85
2 years, 11 months ago
A&B works
upvoted 2 times
quiquisimo
2 years, 9 months ago
yeah, it works in Centos
upvoted 1 times
...
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago