New Year Sale 2026! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

CompTIA XK0-005 Exam - Topic 4 Question 36 Discussion

Actual exam question for CompTIA's XK0-005 exam
Question #: 36
Topic #: 4
[All XK0-005 Questions]

A file called testfile has both uppercase and lowercase letters:

$ cat testfile

ABCDEfgH

IJKLmnoPQ

abcdefgH

ijklLMNopq

A Linux administrator is tasked with converting testfile into all uppercase and writing it to a new file with the name uppercase. Which of the following commands will achieve

this task?

Show Suggested Answer Hide Answer

Contribute your Thoughts:

0/2000 characters
Julie
3 months ago
B and C look wrong to me, just a mess of brackets!
upvoted 0 times
...
Louvenia
3 months ago
Wait, can you really use tr like that? Seems off.
upvoted 0 times
...
Leonard
3 months ago
I thought it was A at first, but D makes more sense.
upvoted 0 times
...
Kiera
4 months ago
Totally agree, D is the way to go.
upvoted 0 times
...
Carissa
4 months ago
Option D is the correct command!
upvoted 0 times
...
Haydee
4 months ago
I feel like I’ve seen a command like this before, but I can't recall if we need to specify the input file correctly. I hope it’s not option A!
upvoted 0 times
...
King
4 months ago
I’m a bit confused about the brackets in the commands. I thought they were supposed to be square brackets, but some options use curly ones.
upvoted 0 times
...
Rodolfo
4 months ago
I remember practicing a similar question where we had to convert text files, and I think option D looks correct since it uses the right character ranges.
upvoted 0 times
...
Marguerita
5 months ago
I think the command should use `tr` to convert lowercase to uppercase, but I'm not sure about the syntax.
upvoted 0 times
...
Rebbeca
5 months ago
Okay, I've got this. The key is to use the correct character ranges in the `tr` command. Option D looks like the cleanest and most direct way to convert all lowercase letters to uppercase. I'm confident that's the right solution.
upvoted 0 times
...
Stanford
5 months ago
Hmm, I'm a bit confused by the different syntax options here. I'll need to double-check the `tr` command usage to make sure I understand the character ranges properly. Let me think this through carefully.
upvoted 0 times
...
Kanisha
5 months ago
This looks like a straightforward question about using the `tr` command to convert the contents of a file to uppercase. I think option D is the correct answer, as it directly specifies to convert all lowercase letters to uppercase.
upvoted 0 times
...
Whitley
5 months ago
I'm not sure about some of these options. The syntax seems a bit tricky, and I want to make sure I get this right. I think I'll try option D first, but I'll also double-check the man page for `tr` just to be sure.
upvoted 0 times
...
Norah
5 months ago
Ugh, email security policies can be so tricky. I'll have to really focus on the details here to figure out the most likely reason. Hopefully I can narrow it down through the process of elimination.
upvoted 0 times
...
Narcisa
5 months ago
I think the key here is to understand what a "CPU ACL" is and how it's different from a regular ACL. The question mentions that no ACLs are showing up in the dropdown list, so I'll need to figure out why that's happening.
upvoted 0 times
...
Ben
1 year ago
Yo, option D is the MVP here. Bet those other options are just trying to be fancy, but we don't need that. Keep it simple, folks!
upvoted 0 times
...
Eladia
1 year ago
Ah, the age-old question of converting a file to uppercase. D is the way to go, no doubt about it.
upvoted 0 times
Mila
1 year ago
I agree, tr '[a-z]' '[A-Z]' < testfile > uppercase is the way to go.
upvoted 0 times
...
Stanton
1 year ago
I think D is the correct command to convert the file to uppercase.
upvoted 0 times
...
...
Allene
1 year ago
Wait, why do we need to redirect the input and output files? Option D seems the most straightforward.
upvoted 0 times
Carman
1 year ago
Redirecting input and output files is necessary to save the changes to a new file. Option D is the correct command to use.
upvoted 0 times
...
Doyle
1 year ago
Option D seems like the best choice. It will convert all lowercase letters to uppercase.
upvoted 0 times
...
...
Barrie
2 years ago
I agree with Essie, D is the correct answer.
upvoted 0 times
...
Essie
2 years ago
But D converts lowercase to uppercase, which is what we need.
upvoted 0 times
...
Lonna
2 years ago
I disagree, I believe the answer is A.
upvoted 0 times
...
Muriel
2 years ago
Hmm, I'm not sure about the syntax of some of these options. I think I'll go with D just to be safe.
upvoted 0 times
Christa
2 years ago
Let's go with D to convert the file to all uppercase.
upvoted 0 times
...
Mila
2 years ago
Yeah, D looks like the correct command.
upvoted 0 times
...
Margart
2 years ago
I think D is the right choice.
upvoted 0 times
...
...
Loreta
2 years ago
Option D looks good to me. It's a simple one-liner that should do the trick.
upvoted 0 times
Shaun
2 years ago
Let's go with option D then, it's a simple and effective solution.
upvoted 0 times
...
Truman
2 years ago
I agree, tr '[a-z]' '[A-Z]' should work perfectly for this task.
upvoted 0 times
...
Reena
2 years ago
Yeah, using tr to convert lowercase to uppercase seems like the way to go.
upvoted 0 times
...
Truman
2 years ago
I think option D is the correct one.
upvoted 0 times
...
...
Essie
2 years ago
I think the answer is D.
upvoted 0 times
...

Save Cancel