ExamGecko
Question list
Search
Search

Related questions











Question 231 - CTFL-2018 discussion

Report
Export

Consider the following code

int premium=2500;

if <age<30)

{

premium = premium +1500:

}

Which options suits for a correct combination of Boundary value and expected result. Assume first number as boundary followed by expected result.

A.
30. 1500 31, 2500
Answers
A.
30. 1500 31, 2500
B.
29,1500 30. 2500
Answers
B.
29,1500 30. 2500
C.
29. 2500 30, 1500
Answers
C.
29. 2500 30, 1500
D.
29.4000 30. 2500
Answers
D.
29.4000 30. 2500
Suggested answer: B

Explanation:

Boundary value analysis is a technique to test the values at the boundaries of an equivalence partition. In this case, the age variable has two equivalence partitions: less than 30 and greater than or equal to 30. The boundary values are 29 and 30. The expected result for age 29 is that the premium is increased by 1500, so the final value is 4000. The expected result for age 30 is that the premium remains unchanged at 2500. This is explained in the syllabus under section 4.3, 'Black-box Test Techniques'1.

Reference: Certified Tester Foundation Level (CTFL) Syllabus - ASTQB

asked 18/09/2024
Monterio Weaver
33 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first