Answered step by step
Verified Expert Solution
Link Copied!

Question

00
1 Approved Answer

Assignment Goals: To learn to use UNIX/Linux file processing utilities to process data in text files. Tasks: 1. In your home directory, make a directory

image text in transcribedimage text in transcribedimage text in transcribedimage text in transcribed

Assignment Goals: To learn to use UNIX/Linux file processing utilities to process data in text files. Tasks: 1. In your home directory, make a directory called hw3 and change to the hw3 directory 2. Use the vi editor to create three text file s1, s2, and s3. Each contains a list of full names as follows. Assume a school department offers three scholarships to students. A student can apply for one scholarship or more scholarships. The files s1, s2, and s3 are students who applied for Scholarship 1, Scholarship 2, and Scholarship 3 respectively. The student names are sorted in the alphabetic order s1 s2 Amanda Jones Amber Johnson Brandon Brown Chris Davis Danie1 Hall Elizabeth Walker Frank Thompson Jack Moore Kevin Young Nick Turner Noah Parker Robert Wright Tyler Cooper Aaron Smith Amanda Jones Ben Miller Brandon Brown Brian Wilson Daniel Hall Edward Thomas Frank Thompsorn George Anderson John Martin Loren Adams Noah Parker Peter Hill Steve Jones Wayne Philips Aaron Smith Brandon Brown Chris Davis David Clark Edward Thomas Jack Moore John Martin Kevin Young Michael Harris Nick Turner Peter Hill Robert Wright 3. Use the vi editor to create a script called hw3script and add commands as follows 3.1. Write commands to find and display the number of students who applied for each scholarship. 3.2. Write commands to find and display students who applied for two scholarships, Scholarship 1 and 2, Scholarship 1 and 3, or Scholarship 2 and 3, respectively 3.3. Write commands to find and display students who applied for all three scholarships Hints: Store results of 3.2 in intermediate files and use them in step 3.3 3.4. Write commands to find a complete list of students who applied for scholarship(s) and output the result to a file named applicants. The result should NOT contain duplicates. Hints: Merge student names in a proper way and remove the duplicates. 3.5. Use a command to replace "Ben" with "Benjamin" in the applicants file and save the output to a new file applicants final 3.4. Write commands to find a complete list of students who applied for scholarship(s) and output the result to a file named applicants. The result should NOT contain duplicates. Hints: Merge student names in a proper way and remove the duplicates. 3.5. Use a command to replace "Ben" with "Benjamin" in the applicants file and save the output to a new file applicants_final. 3.6. Use a command to find all the lines that contain the name "Jones" in the applicants final file. 3.7. Write a command to display the final list of students who applied for scholarship(s). 3.8. Write a command to find and display the total number of students who applied for scholarship(s) 3.9. write a command to output I certify that this submission is my own original work"-' followed by your full name. 4. Add the execute permission to the owner, group, and others for your script file. 5. Run your script. The output should be similar to the sample output listed below. Submission: Submit a word or pdf document that contains the following two screenshots: 1. A screenshot of the contents of your script file, i.e., after running the command vi hw3script cat hw3script 2. A screenshot of the output after running your script file, i.e., after executing /hw3script

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

Question

ap language and composition

Answered: 1 week ago