Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I'm having trouble coming up with the right way to write this in linux. Use 'tr' to convert sed_edits.txt to lowercase and then put each
I'm having trouble coming up with the right way to write this in linux.
Use 'tr' to convert sed_edits.txt to lowercase and then put each word in sed_edits.txt on a single line.
Step 2a convert to lowercase
- Run echo aBcDeF > letters.txt to create a test file
- Run cat letters.txt | tr '
' ' to verify that' and converts uppercase to lowercase - See slide "Useful tr conversions" for hints.
Step 2b one word per line
- HINT: Every word is followed by a space. So what character can be converted to put each word on a single line?
- See slide "Useful tr conversions" for suggestions.
- Run echo a b c d > words.txt to create a test file
- Run cat words.txt | tr '
' ' to verify that' and puts each letter on its own line - Run cat sed_edits.txt | tr '
' ' . It should return the value 1333. NOTE: The 'wc' option is the lowercase "el"' | wc l
Step 2c chain the commands
- Chain all of these 'tr' commands together using the pipe operation and rediect the output to tr_edits.txt
- The command chain should look like
'cat sed_edits.txt | tr '
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started