New Year Sale 2026! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

ASTQB CTFL Exam - Topic 1 Question 69 Discussion

Actual exam question for ASTQB's CTFL exam
Question #: 69
Topic #: 1
[All CTFL Questions]

A software component has the code shown below:

Program BiggestA, Biggest: Integer Begin Read A Biggest = 10 While A > 0 Do If A > Biggest Then Biggest = A Endif Read A Enddo End

The component has exit criteria for component testing that include 100% statement coverage. Which of the following test cases will satisfy this criterion?

Show Suggested Answer Hide Answer
Suggested Answer: D

Contribute your Thoughts:

0/2000 characters
Kyoko
3 months ago
Definitely, option B won't hit all statements.
upvoted 0 times
...
Rosita
3 months ago
Wait, does 100% statement coverage really mean all paths?
upvoted 0 times
...
Edna
3 months ago
Nah, option D covers all the branches too.
upvoted 0 times
...
Tuyet
4 months ago
I think option C is the best choice here.
upvoted 0 times
...
Dick
4 months ago
The initial value of Biggest is set to 10.
upvoted 0 times
...
Hyman
4 months ago
I’m confused about which test cases actually execute the "If" statement. I need to double-check how many times each option reads A.
upvoted 0 times
...
Jaime
4 months ago
I feel like we practiced a similar question, and I think option D could also work because it tests the condition where A is greater than Biggest.
upvoted 0 times
...
Tamekia
4 months ago
I'm not entirely sure, but I think option C might cover all the statements since it includes a value greater than 10.
upvoted 0 times
...
Shelia
5 months ago
I remember we discussed statement coverage and how we need to execute every line of code at least once.
upvoted 0 times
...
Gladis
5 months ago
Easy peasy! The test cases that will satisfy the coverage requirement are the ones that hit the different branches of the conditional statement and the loop. I'd go with option C.
upvoted 0 times
...
Tiera
5 months ago
Okay, I think I've got it. The key is to cover all the different paths through the code, including the case where the input value is greater than the current biggest value.
upvoted 0 times
...
Tamekia
5 months ago
Hmm, I'm a bit confused by the code. I'll need to spend some time understanding how the program works before I can decide on the test cases.
upvoted 0 times
...
Alisha
5 months ago
This looks like a pretty straightforward question. I'll need to carefully trace the logic of the code to determine which test cases will satisfy the 100% statement coverage requirement.
upvoted 0 times
...
Roselle
5 months ago
Hmm, I'm a bit unsure about the details of vSphere Namespaces. Let me think this through carefully.
upvoted 0 times
...
Nicolette
1 year ago
I think the answer is A) 0 because it covers all the statements in the code.
upvoted 0 times
...
Aleshia
1 year ago
Haha, this code looks like it was written by a programmer who just discovered the 'While' loop. But I'd say option C is the way to go.
upvoted 0 times
Shawna
1 year ago
Option C includes all the necessary values for testing this code.
upvoted 0 times
...
Walton
1 year ago
I think option C is the best test case scenario for this code.
upvoted 0 times
...
Cruz
1 year ago
Yeah, option C seems to be the most comprehensive choice.
upvoted 0 times
...
Bev
1 year ago
I agree, option C covers all the possibilities.
upvoted 0 times
...
...
Sylvie
1 year ago
I'm not sure, but I think both C) and D) could satisfy the criteria.
upvoted 0 times
...
Tiffiny
1 year ago
I'm going with C, 10, 5, 0. It's the most comprehensive test case that checks the program's behavior for different input values.
upvoted 0 times
Raelene
1 year ago
I agree, but C) 10, 5, 0 provides more thorough testing with additional input values.
upvoted 0 times
...
Geoffrey
1 year ago
I think B) 10, 0 would also cover all the statements in the code.
upvoted 0 times
...
...
Matthew
1 year ago
I disagree, I believe the answer is D) 10, 11, 0.
upvoted 0 times
...
Junita
1 year ago
I think the answer is C) 10, 5, 0.
upvoted 0 times
...
Stefany
2 years ago
Hmm, I'm torn between B and C. Both seem to cover all the statements, but C might be a bit more thorough in testing the different scenarios.
upvoted 0 times
Eve
1 year ago
I agree, C seems like a more thorough test case.
upvoted 0 times
...
Ilene
1 year ago
I think C covers more scenarios, so it might be the better choice.
upvoted 0 times
...
...
Tresa
2 years ago
D, 10, 11, 0 looks good to me. It covers all the different conditions, including the edge case where the input is greater than the current biggest value.
upvoted 0 times
...
Pauline
2 years ago
I think option B, 10, 0, is the answer. It hits all the statements in the code and satisfies the 100% statement coverage.
upvoted 0 times
Idella
1 year ago
I believe option D is incorrect, as it includes a value that is not greater than 10.
upvoted 0 times
...
Remedios
1 year ago
I think option C might also work, as it includes more values to test.
upvoted 0 times
...
Werner
1 year ago
I agree, option B covers all the statements in the code.
upvoted 0 times
...
...

Save Cancel