Creating a unix shell script

Assignment Help Data Structure & Algorithms
Reference no: EM1380536

Question: Design a Unix shell script that searches for a text document with most occurrences of a given keyword. For instance, if I would like to search for a script with most usages of if statement, I would execute:

find_most_relevant.sh /home/student/myscripts if

The script find_most_relevant.sh should take two arguments. The first one is the directory where text files are located. The second argument is a keyword. The output of the script should either state:

No file with word <keyword> found in the directory <directory-name>

Or

file <filename>: found X occurrences of word <keyword>

(for the file with most occurrences of keyword only)

 

Reference no: EM1380536

Questions Cloud

How does goal setting disturb the performance : How does goal setting disturb the performance of the player on the Colts team? How do you ponder the Colts players would rate their job satisfaction? Why is this significant to the performance of the team as a whole?
Illustrate what would you recommend that they do. : WLAN worked well for one semester, but now more students have laptops with Wi-Fi built in also performance has deteriorated significantly. Illustrate what would you recommend that they do. Be sure to support your recommendations.
What is your dint of bernstein''s perception on raising : David Bernstein wants help financing his Lodi, New Jersey based Access Direct Inc., a six-year-old $3.5 million company. We're set to get to the next level
Explain why you believe author demonstrates good critical : Explain why you believe author demonstrates good critical thinking also whether article meets criteria as explained in Cornell University site.
Creating a unix shell script : Design a Unix shell script that searches for a text document with most occurrences of a given keyword. For instance, if I would like to search for a script with most usages of if statement,
Detailing the antitrust claims faced by the microsoft : Prepare a two to three page paper subsequent the APA guidelines detailing the antitrust claims faced by the Microsoft Corporation as thorough in the above websites
Illustrate what must carter prove to establish a rebuttable : Carter brings suit against Harper also Jennings alleging disparate treatment discrimination. Illustrate what must Carter prove to establish a rebuttable presumption of disparate treatment. If Carter establishes rebuttable presumption, does Harper ..
Is organization more appropriately illustrated as centralize : Is organization more appropriately illustrated as centralized or decentralized also Explain why.
Leadership via vision is essential for success : Leadership via vision is essential for success. Deliberate in detail research the topic the qualities that a leader should exhibit in order to be considered visionary and further

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  Data speed effect on fundamental business decisions

Can the speed in which data is transmitted have an adverse effect on fundamental business decisions? Yes, speed that is traveling at big rates of speed can have an affect on fundamental business decisions.

  Choosing computer passwords

Before logging on to computer, you must have a unique username and unique password. Analyze and explain considerations you must make when choosing a password.

  Explain an application level protocol

Create and explain an application level protocol to be used in an automatic teller machine and a bank's centralized computer. Your protocol should permit a user's card and password to be verified,

  Creating a chart for it system

Make a chart that demonstrate the breakdown of the overall IT systems at a big corporation or breakdown a particular aspect of the IT systems such as the network or the business applications systems.

  Creating the table showing decimal value

Assume if the last digit of a 2's complement binary number is 0, then number is even. If the last two digits of a 2's complement binary number are 00

  Question about pointerlists

Whenever the pointer of a list or a tree is manipulated, procedure that performs this operation must be considered to be in a critical section.

  Design randomized algorithm for solving decoding problem

The Viterbi algorithm is a deterministic algorithm for solving the Decoding problem. Design a randomized algorithm for solving the Decoding problem.

  Greedy strategy for finding a shortest path

Think about the given greedy strategy for finding a shortest path from vertex start to vertex goal in a connected graph.

  Programming language problems

Many programming languages do not permit you to ask two or more questions in a single comparison by using a logical And Operator

  Explaining instruction format of operation code field

Operation code field, a mode field, to specify one of seven addressing modes, a register address field to specify one of 60 processor registers, and memory address. Specify instruction format and number of bits in each field if the instruction ..

  Algorithm-decide whether language recognized by dfa is empty

Give an algorithm to decide whether the language recognized by a DFA is empty. Given two DFAs M1 and M2, give an algorithm to decide whether L(M1)subset or equal to L(M2).

  Linear-time algorithm to find odd-length cycle in graph

Give a linear-time algorithm to find an odd-length cycle in a directed graph. You may not suppose that graph is strongly connected.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd