Program to perform a search of an employee list

Assignment Help Programming Languages
Reference no: EM131614

Write a /bash/bin program to perform a search of an employee list. The file emplist has the format given in the table below and contains information about an upcoming paintball game.

Columns

Data field

01 - 11

Department

12 - 26

Player name

27-39

Team Name

40- 54

Target

55-58

Status (full-time, retired, etc.)

Example of the " emplist " file... (The first two lines represent columns numbers, not in file)

0        1         2         3         4         5         6         7
1234567890123456789012345678901234567890123456789012345678901234567890
Marketing  Ken Whillans   Eagles       Karen Thompson FULL
President  Sandeep Jain   Wimps        Ken Whillans   CONT
...
etc...
Program Requirements
  • Continually prompt the user to enter a player's name or portion thereof (should not have to re-run program for each search).  Use "ZZZ" to exit program.
  • Ask the user if s/he wishes to see the corresponding target (T/t) or team name (M/m); reject any other input with an error message ("Please enter only T or M.") and re-prompt user.
  • Search only the player field of the data file displaying the all occurrences of matching player(s) and corresponding target or team name.
  • E.g. A search for the target of "Ken", should not display any information about "Sandeep". i.e. the search must be restricted to the information in the player column.
  • Use the sample data file from the course website.
  • If no player is found, your program should output a short message to the effect "No such player."
  • If you create any temporary files, they must be cleaned up by your program before it terminates.

Sample execution (not exhaustive testing):

$ search
Player name? ohn
See target (T/t) or team name (M/m)? j
Please enter only T or M.
See target (T/t) or team name (M/m)? t
John Thompson Cher
John Jacobs   Davinder Singh
Dean Johnson  Sandeep Jain
Player name?..

Reference no: EM131614

Questions Cloud

Income adjustment : To maintain utility constant an income adjustment brought the student to consume the basket (61,92). What are substitution effects and the income ?
Retirement plans : How much will Jane have in her retirement account immediately after she makes her last contribution in Year 40, assuming a return on her investments of 9%?
Lender - borrower relationship : The following questions are focused on a specific Lender / Borrower relationship
Budget allocation : Budget allocation - calculate the end values at the end of the respective periods.
Program to perform a search of an employee list : Write a /bash/bin program to perform a search of an employee list.
Investment comparison problems : This Assignment consists Investment Comparison Problems.
Bonds nominal yield to maturity : What is the current yield on these bonds and  What is the bond's nominal yield to maturity.
Investment management assignment : Prepare a report recommending the appropriate investment of AUD$3 million for a five year investment period for a particular investment client.
Neolithic revolution : What  was the Neolithic Revolution. Explain

Reviews

Write a Review

Programming Languages Questions & Answers

  Create a simple shell

Create a simple shell. Basically your shell should read the line from standard input, parse the line with command and arguments, and operate the command with arguments.

  Ethics and social responsibility

Ethics and social responsibility at McDonalds

  Writing a class

Build a class for a type called Fraction

  Discussion: html/css

Discussion: HTML/CSS,  "JavaScript Placement"  Please respond to the following: Compare and contrast the process of adding JavaScript and a Cascading Style Sheet to a Website. Determine if they can be used simultaneously in a page. If so, explain wh..

  Building instruction set simulators

Building Instruction Set Simulators

  Accuracy and completeness of computations

Analysis right and you have to develop a plausible argument to "prove" that your analysis is correct

  Develops bespoke solutions for the rubber industry

Develops bespoke solutions for the rubber industry

  Questions on programing problem with the process of analysis

Questions on Programing Problem with the process of analysis and reflection that went on as you developed the project.

  Learn redirecting standard output

Learn redirecting standard output (stdout) to a file using the output redirection operator

  Basics of hypertext markup language

The basics of Hypertext Markup Language and World Wide Web.

  Programming problem

Programming Problem can be solved by a program that performs three basic tasks-Input Data, Process Data, and Output Results.

  Create a project in xcode

Create a new project in XCode using the Mac OS X/Command Line Tool template

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