LPI
101-500 · Question #31
Which of the following commands will reduce all consecutive spaces down to a single space?
The correct answer is E. tr -s ' ' < a.txt > b.txt. You've hit your Sonnet limit · resets Jun 8, 9am (UTC)
GNU and Unix Commands
Question
Which of the following commands will reduce all consecutive spaces down to a single space?
Options
- Atr '\s' ' ' < a.txt > b.txt
- Btr -c ' ' < a.txt > b.txt
- Ctr -d ' ' < a.txt > b.txt
- Dtr -r ' ' '\n' < a.txt > b.txt
- Etr -s ' ' < a.txt > b.txt
How the community answered
(17 responses)- A18% (3)
- B6% (1)
- D6% (1)
- E71% (12)
Explanation
You've hit your Sonnet limit · resets Jun 8, 9am (UTC)
Topics
#tr command#text processing#squeeze flag#command options
Community Discussion
No community discussion yet for this question.