Answered step by step
Verified Expert Solution
Link Copied!

Question

00
1 Approved Answer

1. Consider the following file listings. What information does each highlighted fields provide? [4 marks] a) drwxr-xr-x 5 nargis staff 4096 Feb 022022 flower 1

image text in transcribed

1. Consider the following file listings. What information does each highlighted fields provide? [4 marks] a) drwxr-xr-x 5 nargis staff 4096 Feb 022022 flower 1 nargis staff 2495 Feb 022022 food.txt 2. Assume you are under your home directory. Explain what would be the result of issuing the following command? [3 marks] ls 1 a?.txt | sort r tail 3> sortedscript.txt 6. In this question you will use the many file-processing tools you've learned 1. Write the command for each of the following questions. a. Create a file called vendors.txt consisting of two colon-separated fields: the vendor number and vendor name: [1 marks] 1201:Cromwell Interiors 1221:Design Extras Inc. 1320:Piedmont Plastics Inc 1340:Morgan Catering Service Ltd. 1350:Pullman Elevators 1360:Johnson Office Products b. Create another file called products.txt consisting of three colon-separated fields: the product number, the product description, and the vendor number: [1 marks] S0107:Lobby Furniture:1201 S0109: Ballroom Specialties:1221 S0110:Poolside Carts:1320 S0130:Formal Dining Specials:1340 S0201:Reservation Logs:1410 c. Use the cut, paste, and sort commands as follows to create a single-example vendor report: (write command for each of the following steps) [11 marks] CPAN133 i. Use the cut command to extract product descriptions and vendor numbers from the products file and store them in separate files called p1 and p2. ii. Extract vendor number and vendor names from the vendors file and store them in separate files called v1 and v2. iii. Use the paste command to combine v1 and v2, save in v3 iv. Use the paste command to combine p1 and p2,save in p3 v. Sort and merge the v3 and p3 files using the sort command and send their output to the vrep file (which is the report). Write the command and also take a screenshot of this output and add here

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions