Professional Documents
Culture Documents
Assignment#02
Submitted To:
Mam Najmun Nisa
Date:
November 22, 2020.
Question 1:
Every person receives a benefit of 350. In addition, it is determined whether a person has worked
and that his/her age is higher than 40. In this case the benefit is raised by 100. Alternatively
(else) for persons that are not working and have exactly 4 children the benefit is raised by 50.
b) Identify the test cases both for valid and invalid cases.
Test Cases:
Test cases are written in such a way that they cover all valid and invalid equivalence classes.
One test case should include all valid equivalence classes and the other. The remaining test
cases should cover only one invalid class at a time because if we place multiple invalid classes
in one test case, then all test cases that will come after this test case will never be executed. In
this way, if any error occur due to multiple invalid inputs then this test case terminate the
execution of remaining test cases.
In the above table, TC-01 contains all valid equivalence classes, TC-02 and TC-03 contain all
invalid classes and the remaining test cases cover only one invalid class at a time.
Question 2:
The program reads three integer values from a card. The three values are interpreted as representing the
lengths of the sides of a triangle. The program prints a message that states whether the triangle is
scalene, isosceles, or equilateral.
Write a set of test cases that would adequately test this program.