NPTEL Software Testing Week 3 Assignment Answers 2024

admin
By admin

NPTEL Software Testing Week 3 Assignment Answers 2024

1. State true or false: The control flow graph fragments for loops like while, for etc., can vary slightly and this is acceptable as long as the control flow is captured correctly.

  • True.
  • False.
Answer :- For Answers Click Here

2. A node or a set of nodes that in a particular control flow graph that cannot be reached through DFS or BFS represents which kind of statements in the corresponding program source code?

  • These node(s) represent statements that are incorrect.
  • These node(s) represent statements that are not reachable by any input.
  • These node(s) represent statements that are reachable only by inputs that are wrong or out of range.
  • These node(s) represent statements that will not contribute to generating outputs when the program is executed.
Answer :- For Answers Click Here

3. Given a piece of source code, what is the information about the data that is captured in a data flow graph corresponding the code?

  • A data flow graph tracks information about how a value of a variable changes.
  • A data flow graph captures information about how a variable gets defined, in the sense, the kind of statement that defines a variable.
  • A data flow graph captures information about the statements that define a value for a variable and statements that use the defined value of a variable.
  • A data flow graph tracks the change of data from the statements where the variables are defined to the statements where the variables are used.
Answer :- 

4. Which of the following represents a correct order of subsumption exclusively amongst data flow coverage criteria? In the options below, read → as ‘subsumes’.

  • All-defs coverage → All-du-paths coverage → All-uses coverage.
  • All-defs coverage → All-uses-coverage → All-du-paths coverage.
  • All-du-paths coverage → All-defs coverage → All-uses-coverage.
  • All-du-paths coverage → All-uses coverage → All-defs-coverage.
Answer :- For Answers Click Here

5. onsidering the coverage criteria on both control flow graphs and data flow graphs, which of the following represents a correct order of subsumption amongst the mentioned criteria? Again, read → as ‘subsumes’.

  • Prime paths coverage → All-du-paths coverage.
  • All-du-paths coverage → Prime paths coverage.
  • Since one kind of criteria are on control flow only and the other on data flow only, the two cannot be compared.
  • None of the control flow coverage criteria subsumes any of the data flow coverage criteria.
Answer :- 

6. List all the nodes where the variable z is defined

W3Q6 ST
  • Node 6 only.
  • Nodes 3, 4 and 6 only.
  • Nodes 3, 4, 5 and 6 only.
  • Nodes 2, 3, 4, 5 and 6 only
Answer :- 

7. Which of the statements below are correct regarding the definitions and uses of the variables x and y?

  • The nodes that define the variables x and y are the same.
  • The nodes that define and use the variables x and y are the same.
  • The nodes and edges that define the variables x and y are the same.
  • The nodes and edges that define and use the variables x and y are the same.
Answer :- For Answers Click Here

8. State yes or no: The use of the variables at the edges (2, 3) and (2, 4) are the same as the use of the variables at the nodes 3 and 4.

  • Yes.
  • No.
Answer :- 

9. How many du-pairs are there for the variable z?

  • Eight du-pairs.
  • Nine du-pairs.
  • Ten du-pairs.
  • Eleven du-pairs.
Answer :- 

10. How many unique du-paths are there for the variable z?

  • Four paths.
  • Five paths.
  • Six paths.
  • Seven paths.
Answer :- For Answers Click Here
Share This Article
Leave a comment