1. What is the statement domain for P1? Express as line numbers. Exclude syntactical markers, such...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
1. What is the statement domain for P1? Express as line numbers. Exclude syntactical markers, such as { }, else, and end. 2. What is the statement coverage of T for P1? Express as an unsimplified fraction. 3. If the statement coverage of T for P1 is less than 100%, what test cases could you add to get 100% statement coverage? 4. What is the decision domain for P1? Express as "line number) decision". 5. What is the decision coverage of T for P1? Express as an unsimplified fraction. 6. If the decision coverage of T for P1 is less than 100%, what test cases could you add to get 100% decision coverage? Program Pl 1) 2) 3) 4) 5) 6) 7) 8) 9) 10) 11) 12) integer A, B; input (A); while (A > 0) { B = 1; if (A < 10) B = 0; if (A < 20 or A > 25) B = A * B; else B = A + B; output (A, B); input (A); 13) 14) } 15) output ("Program ends."); 16) end; T = {t₁=<1>, t₂=<33>, t3=<-1>} 1. What is the statement domain for P1? Express as line numbers. Exclude syntactical markers, such as { }, else, and end. 2. What is the statement coverage of T for P1? Express as an unsimplified fraction. 3. If the statement coverage of T for P1 is less than 100%, what test cases could you add to get 100% statement coverage? 4. What is the decision domain for P1? Express as "line number) decision". 5. What is the decision coverage of T for P1? Express as an unsimplified fraction. 6. If the decision coverage of T for P1 is less than 100%, what test cases could you add to get 100% decision coverage? Program Pl 1) 2) 3) 4) 5) 6) 7) 8) 9) 10) 11) 12) integer A, B; input (A); while (A > 0) { B = 1; if (A < 10) B = 0; if (A < 20 or A > 25) B = A * B; else B = A + B; output (A, B); input (A); 13) 14) } 15) output ("Program ends."); 16) end; T = {t₁=<1>, t₂=<33>, t3=<-1>}
Expert Answer:
Answer rating: 100% (QA)
To answer these questions we need to understand the code provided in Program P1 and the test cases in set T Heres the code for Program P1 for referenc... View the full answer
Related Book For
Fundamentals of corporate finance
ISBN: 978-0470876442
2nd Edition
Authors: Robert Parrino, David S. Kidwell, Thomas W. Bates
Posted Date:
Students also viewed these programming questions
-
Find the 99% confidence interval for the population standard deviation given the following. (I point) n=17,-472,.-26.9 and the distribution is normal.
-
To whom will your candy bar be sold? What is it ? ( Product ) Specify features, benefits, form, size, etc. How much will consumers pay for it ? ( Price ) How will consumers find out about it ? (...
-
Carrie Wilson, a registered nurse with more than 10 years ofactive supervisory experience, was hired from outside as nursingmanager for the emergency department of County Hospital. It wasCarries...
-
There are different types of non-probability sampling methods. Below are examples of such methods. You are required to go through them and (for each example); a. Name the Sample Method b. Write a not...
-
The system shown in FIGURE 6-45 consists of two pulleys and two blocks. The pulleys each have a mass of 2.0 kg, the block on the left has a mass of 16 kg, and the block on the right has a mass m. The...
-
A manufacturing companys quality control personnel have recorded the proportion of defective items for each of 500 monthly shipments of one of the computer components that the company produces. The...
-
A survey of German adults found that 73% of customers who shop online pay through PayPal. You randomly select 150 German adults who shop online. Find the probability that the number who pay through...
-
Operating profits and losses for the seven operating segments of Foley Corporation are (in 000,000): Based only on the operating profit (loss) test, which industry segments arereportable? Penley...
-
2. Write ARM Thumb-2 Assembly language code to perform the following logic: int Chose (int choice) 1 switch (choice) { case 'A': print("You choose: A "); break; case 'B': print("You choose: B ");...
-
In the student sample program files for this chapter, you will find a text file named GasPrices.txt. The file contains the weekly average prices for a gallon of gas in the United States, beginning on...
-
Jack is a top-level executive at Bigco Industries, earning $540,000 of salary each year. Jen is a psychology professor at State University earning $94,000 per year.In fall 2022 Jen took a sabbatical...
-
Should preferred stock be recognized as a liability, or should it be considered equity? Under International Financial Reporting Standards, preferred stock ( preference shares ) often is reported as...
-
Journal entries and trial balanceElite Realty acts as an agent in buying, selling, renting, and managing real estate. The unadjusted trial balance on March 3 1 , 2 0 Y 3 , follows:Elite...
-
Background: Imagine you work for a tech company that is about to launch a new smartphone in a highly competitive market. The company's success will heavily depend on how well it prices the new...
-
On April 1 , Waterway Industries purchased for $ 1 6 5 6 0 0 0 a tract of land on which a warehouse and office building was located. The following data were collected concerning the property:Current...
-
Please fill table below Probability Expected return for Bond A Expected return for Bond B 0.05 12.0% 2.0% 0.30 10.0% 3.0% 0.35 9.0% -3.0% 0.20 6.0% 2.0% 0.10 3.0% -4.0% 1 Expected return for A 2...
-
Explain Cimabue Madonna Enthroned?
-
State whether each statement is true or false. If false, give a reason. {purple, green, yellow} = {green, pink, yellow}
-
Knight Supply Corp. has not grown for the past several years and management expects this lack of growth to continue. The firm last paid a dividend of $3.56. If you require a rate of return of 13...
-
What are some of the ways in which a financial institution or intermediary can raise money?
-
What are the key events and dates in the dividend payment process?
-
The control volume shown in Figure \(P 2.15\) has steady, incompressible flow, and all properties are uniform at the inlet and outlet. For \(u_{1}=1.256 \mathrm{MJ} / \mathrm{kg}\) and...
-
(a) List the forces exerted on the spring-cart system of Figure 15.1 right after it is released, and draw a freebody diagram for each object in the system. (b) Which of these forces do work on the...
-
(a) In Figure 15.2e, the cart's displacement from the equilibrium position is maximum. Is the \(x\) component of the cart's acceleration at that instant positive, negative, or zero? (b) At which...
Study smarter with the SolutionInn App