Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Can u any 1 please explain the below question and answer?
Given the following code, which statement is true about the
minimum number of test cases required for full statement and
branch coverage?

Read p
Read q
IF p q > 100 THEN
Print "Large"
ENDIF
IF p > 50 THEN
Print "p Large"
ENDIF

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

Answers were Sorted based on User's Feedback



Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / chakkaravarthi

answer is B

Is This Answer Correct ?    18 Yes 1 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / suyash

The answer is B.
Statement Coverage (SC):
To calculate Statement Coverage, find out the shortest
number of paths following
which all the nodes will be covered. Here by traversing
through path 1A-2C-3D-E-4G-5H all
the nodes are covered. So by traveling through only one path
all the nodes 12345 are covered,
so the Statement coverage in this case is 1.
Branch Coverage (BC):
To calculate Branch Coverage, find out the minimum number of
paths which will
ensure covering of all the edges. In this case there is no
single path which will ensure coverage
of all the edges at one go. By following paths
1A-2C-3D-E-4G-5H, maximum numbers of
edges (A, C, D, E, G and H) are covered but edges B and F
are left. To covers these edges we can follow 1A-2B-E-4F. By
the combining the above two paths we can ensure of traveling
through all the paths. Hence Branch Coverage is 2. The aim
is to cover all possible true/false
decisions.

Is This Answer Correct ?    10 Yes 2 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / dmitry

Correct Answer is "B"

b) 1 test for statement coverage, 2 for branch coverage

1) Statement coverage - 1 test.

P must be > than 50
P+Q must be > than 100

All statements (8 rows) are covered (used).

2) Decision coverage - 2 tests

2.1 P must be > than 50
P+Q must be > than 100

All "TRUE"(YES) decisions (1 and 2) are covered

2.1 P must be < than 50
P+Q must be < than 100

All "FALSE"(NO) decisions (1 and 2) are covered

Is This Answer Correct ?    3 Yes 1 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / dhruv

if p=55 and q=40 then?

Is This Answer Correct ?    6 Yes 6 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / jyoti

Yeah , answer in D , since two question have been asked ,
and 2 branches we are covering , since statement coverage is
class, and Branch coverage that we are covering all if
statement and there are two if's

Please let me know if anybody finds this is wrong

Is This Answer Correct ?    2 Yes 7 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / nayana

a) 1 test for statement coverage, 3 for branch coverage

Since inputs are not specified the above answer is
correct
If inputs are given then apply the given inputs in the
given code & then check it & to confirm u can draw the flow
diagram & check it.
For example u can apply p = 70 & q = 40
For the above inputs, (a) is correct answer

Is This Answer Correct ?    9 Yes 15 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / guest

Answer is a

Is This Answer Correct ?    2 Yes 9 No

Can u any 1 please explain the below question and answer? Given the following code, which statement ..

Answer / vaishali

it wud be 2 testcasese for statement coverage and 2 for
branch coverage
2 for statement coverage bcaz two seperate questions being
asked
p+q>100 and p>50

and its two branches with NO hasnt been covered....

so, answer is 2 testcasese for statement coverage and 2 for
branch coverage

Is This Answer Correct ?    3 Yes 13 No

Post New Answer

More Manual Testing Interview Questions

Hi, I am planing to give ISTQB - Foundation level exam. Can anyone forward the ISTQB materials at laxmi_002@rediffmail.com mail ID.

0 Answers  


Can anybody send me sample test case for GUI testing for a web page? for eg Homepage

1 Answers  


Please send any one latest 3+ years of experience testing tools resumes my mail id is krishnavenimodaliar26@gmail.com

0 Answers   ME,


How can u do the performance testing?

2 Answers   Wipro,


What is accessibility testing

18 Answers   Aspire,


wat is the diffrence b/n dyanamic blackbox testing and static black box testing.and which one is better

5 Answers   TCS,


I went RightPath Hyderabad Fresher Job on Testing the following Questions they asked...

2 Answers  


How can we test the maximum number of search results a Search Engine (like google) should produce?

0 Answers   Hewitt,


how many members are involved in test plan? and tell me names?

3 Answers   Wipro,


In development costs what percent Software testing accounts?

3 Answers   Covansys,


How to prepare traceability matrix?

1 Answers  


Hi everybody. In an interview i was asked to write the ECP for the range (1-10).

11 Answers   IBM,


Categories