Interview Questions

Given the following code, which is true:IF A > B THENC = A – BELSEC = A + BENDIFRead DIF C = D ThenPrint “Error”ENDIF

Software Testing Exam from International Software Testing Qualifications Board (ISTQB)


(Continued from previous question...)

Given the following code, which is true:IF A > B THENC = A – BELSEC = A + BENDIFRead DIF C = D ThenPrint “Error”ENDIF

Given the following code, which is true:IF A > B THENC = A – BELSEC = A + BENDIFRead DIF C = D ThenPrint “Error”ENDIF

a) 1 test for statement coverage, 3 for branch coverage
b) 2 tests for statement coverage, 2 for branch coverage
c) 2 tests for statement coverage. 3 for branch coverage
d) 3 tests for statement coverage, 3 for branch coverage
e) 3 tests for statement coverage, 2 for branch coverage

Answer:

(Continued on next question...)

Other Interview Questions