CS FundamentalsVery hardCapgemini · HCL
A module contains functions to print to screen, write to a file and send over a network; a flag argument decides which one runs. Which cohesion level is this?
- A. Functional cohesion
- B. Sequential cohesion
- C. Temporal cohesion
- D. Logical cohesion
Correct answer: D. Logical cohesion
Elements are grouped because they are of the same logical category (output), with a control flag selecting the task, which is logical cohesion.
Practise more Software Engineering, Git and Cloud Basics questionsSoftware Engineering, Git and Cloud Basics: notes and key points
More Software Engineering, Git and Cloud Basics questions
- A load balancer with 99.9% availability fronts two redundant servers (parallel), each with 90% availability. System works if the balancer…
- A mutation test run generated 40 mutants. 4 are equivalent mutants and 28 were killed. What is the mutation score, excluding equivalent…
- Branch main has commit A. Branch feature was created from A and has commits B and C. After git merge --no-ff feature on main, how many…
- An object wraps another object that implements the same interface, adding behaviour dynamically before or after delegating (as…
- Module A calls B and C; B calls D and E; C calls F. In top-down integration testing with depth-first ordering, in which order are modules…
- For a one-month Sprint, the Scrum Guide's maximum time-boxes are 4 hours for the Sprint Review and 3 hours for the Sprint Retrospective…