What is the smallest number of test cases required to Provide 100% branch coverage?

If(x>y) x=x+1;

else y=y+1;

while(x>y)

{

y=x*y; x=x+1;

}

A. 1

B. 2

C. 3

D. 4

Answer Posted / toshimathur

B

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the component testing?

754


how to test stand alone programs?

2077


There is French dictionary and if you want to check it in English and there is no documentation available then how you will test it and write a test case and Test scenario on it.

3080


1.If there are so many test cases to be run suppose (100).How will we run those test cases.(using batch) 2. How will we perform over riding in QTP can any one please give me script. thanks

2191


How does the size of the OPCODE field limit the number of operations? Give an example to support your explanation?

1940






How to write test case for this scenario. If the Zip Code field is populated, the system shall compare  the zip code value entered to the zip code value in  the Family Individual Information Tab

8504


Do you know explain security testing?

687


How to write test case for this scenario. The system shall allow for a wild card search for the first name with a minimum of one character.

1438


how to write test cases for the example state name starts with A B C D E F G H I J K L Z

2069


How to write test case for this scenario. The Contact Information screen shall be displayed to the user during Case Update

1523


Write a test case on online shopping website? (please tell me the format how to write in MS excel,if u have any sample than attach it.)

3889


How to write test cases for "hotel reservatrion" for ms word? Thanks a lot!

667


Write a test case for a car, which has been, recently launch in a market to check its durability, fuel efficiency and its optimum speed.

2082


Roads concatenation Problem Consider we have some GIS (Geo Information System) operating over some road network. Each road represented as array of two-dimensional geographical points. Road network is a set of roads. System has function called Concatenate(). This function takes raw road network and should return optimized road network. Optimization lies in concatenating roads with matching start or end points, i.e. if road AB end point matches road BC start point, then optimized network should contain concatenated road AC. Optimized network shouldn’t contain two roads which can be concatenated. Your task is to suggest set of test cases for Concatenate() function in order to make sure it works correctly. public interface IPoint { double Lat { get; } double Lon { get; } } public Road : List { } public RoadNetwork : List { } public RoadNetwork Concatenate(RoadNetwork roads);

1926


Hi Team, I have two scenarios ,only one step alone deference betweeen them and preconditions of Test scenarios are defferent . In the above sutuation , are we going divide test cases into two or can we club into them into a single. Regards seshu

1770