Creating a file reader

Assignment Help Basic Computer Science
Reference no: EM13762247

The program begins by creating a File Reader object and a BufferedReader object to read the file terms.txt. This comma-separated data file contains technical terms in five languages namely, English, Irish, Italian, Spanish and French and is in alphabetical ascending order on the English language entries. The following are two sample entries from this file.

OK, Ceart go leor, Attendere, Aceptar, OK Welcome, Fáilte, Benvenuti, Bienvenido, Bienvenue

This program allows the user to enter a word or phrase (it is assumed that this entry is a word or phrase of the English language). The program returns all equivalent translations of this word or phrase if it exists in the data file. For example, if the user enters the word welcome the program will display output similar to that shown in Figure A2.2. An appropriate message is displayed if the word or phrase is not found in this data file.

For the program you are required to complete the following:

(a) Write test cases to achieve 100% statement coverage of this program. For each test case you should write its test case number, its description, expected outcome and actual outcome.
(b) Draw a Control Flow Graph (CFG) for this program.
(c) Using your CFG write test cases to achieve
(i) 100% decision/branch coverage and
(ii) 100% condition coverage.
For each test case you should write its test case number, its description, expected outcome and actual outcome. In your answer you should identify whether a particular test case concerns decision/branch testing or condition testing

Reference no: EM13762247

Questions Cloud

Ethics case-magnetic toys can hurt : Mega Brands has been selling Magnetix toys for many years. It also sells Mega Bloks, construction toys based on Spider-Man, Pirates of the Caribbean, as well as other products in over 100 countries.
Corporations and professional accountants : What are philosophy approaches to ethical decision making relevant to modern corporations and professional accountants?
Narrows the spectrum to the mean-median : Trend forecasters, sometimes called "futurists," use three "P's": Possible, Probable, and Plausible. "Possible" includes the "outliers" on the classic bell curve. "Probable" narrows the spectrum to the mean, median, and mode at the top of the be..
Write a book review of macbeth : Write a Book review of Macbeth.
Creating a file reader : The program begins by creating a File Reader object and a BufferedReader object to read the file terms.txt.
Soil infiltration and runoff problem : The smooth mountain rock surface type affect the amount of runoff.
What contribution would you like to make : How would you like to affect the history of education? What contribution would you like to make? What do you hope you are remembered for?
Explain the importance of competition among firms : Explain the importance of competition among firms and Explain whether the competitive environment in this industry benefits society or not.
Develop a conversion strategy : Implementing Target was a major undertaking for a number of reasons. If you were an analyst on the project, what kinds of issues would you have to address to make sure the conversion happened successfully

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

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