Problem Solving with C++ (9th Edition)
Problem Solving with C++ (9th Edition)
9th Edition
ISBN: 9780133591743
Author: Walter Savitch
Publisher: PEARSON
Question
Book Icon
Chapter 5.4, Problem 20STE
Program Plan Intro

Testing:

  • It denotes an activity to check whether actual results match expected results.
  • It guarantees that software system is defect free.
  • It involves execution of a software component for evaluating one or more interest properties.
  • It identifies errors, gaps or requirements that are omitted related to actual requirements.
  • It could be performed manually or using automated tools.
  • It can be classified as white or black box testing.
  • The manual testing would include testing of software short of any tool.
    • The tester behaves as an end-user.
    • It tests software for identifying any behavior that is unexpected.
    • The different stages include unit, integration, system as well as user acceptance testing.
  • The automation testing uses software to test product.
    • It includes automation for a manual process.
    • The test scenarios are been re-run that are been performed manually.
    • It is used for testing application from performance, load in addition to stress view point.

Driver program:

  • The driver program contains program’s main function.
  • It is responsible for launching program operations.
  • It is responsible for converting user program into physical execution unit termed as task.
  • Each function must be designed, tested and coded as a discrete unit from rest of program.
  • It denotes a testing program for functions or statement that is been written in code.
  • It tests the functionality usually for debugging as well as code verification.

Given addTax function:

//Define method addTax

void addTax(double taxRate, double& cost)

{

//Compute cost

cost = cost + ( taxRate/100.0 ) * cost;

}

Explanation:

  • The method “addTax()” takes input values as arguments.
  • It computes the cost by using input values entered by user.
  • The result of operation is been displayed.

Blurred answer
Students have asked these similar questions
How we can pass the function pointer as a parameter give example.
Do you have to use the template prefix for each function in the class defini- tion? Do you have to use the template prefix for each function in the class implementation?
Discuss why you must learn both techniques if you can achieve the same result using a value-returning function vs. a void function and passing parameters by reference. Discuss security implications of using pass-by-reference.

Chapter 5 Solutions

Problem Solving with C++ (9th Edition)

Knowledge Booster
Background pattern image
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
C++ Programming: From Problem Analysis to Program...
Computer Science
ISBN:9781337102087
Author:D. S. Malik
Publisher:Cengage Learning