Question: 7 . Write a sed script to do the following, without using line numbers, except when referring to the first line: - Print the lines

7. Write a sed script to do the following, without using line numbers, except when referring to the first line:
- Print the lines with continent info with:
-- the first semicolon (;) changed to colon (:)
-- all commas removed from the numbers in the 2nd field
- Remove the first line
- Change each blank line to a line of equal signs (=)
Your screen output should be: ===========
Africa:11730000;87.15
Asia:16920000;246.11
Australia:3478200;8.37
Europe:3930000;187.84
North America:9460000;57.29
South America:6890000;56.90
===========
To document step 7 in your output file:
- If you use the script utility to record your answer, there are 2 steps:
-- Use the cat command to display your sed script
-- Then run the sed script to produce the output
- If you dont use the script utility to record your answer, there are 3 steps:
-- copy your sed script to the output file
-- run the sed script to produce the output
-- copy and paste both the sed command line and the output

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!