

















































































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
A comprehensive review guide covering programming principles, software architecture, testing methodologies, security practices, and development workflows. The content includes coding scenarios, exam-focused summaries, and practice assessments to enhance software development expertise.
Typology: Exams
1 / 89
This page cannot be seen from the preview
Don't miss anything!


















































































Question 1. Which type of requirement describes the system’s performance under a specified load? A) Functional requirement B) Non-functional requirement C) Process requirement D) Domain requirement Answer: B Explanation: Performance is a quality attribute, thus a non-functional requirement. Question 2. In the requirements elicitation phase, which technique is most effective for uncovering hidden stakeholder needs? A) Document analysis B) Brainstorming session C) Interview with open-ended questions D) Use-case walkthrough Answer: C Explanation: Open-ended interviews encourage stakeholders to reveal tacit requirements. Question 3. A Software Requirements Specification (SRS) should contain which of the following sections? A) System architecture diagram only B) Detailed source code listings C) Functional and non-functional requirements, and interface descriptions D) Project schedule and budget Answer: C
Explanation: An SRS defines what the software must do (functional), how it must behave (non-functional), and interface details. Question 4. Traceability matrices are primarily used to: A) Estimate project cost B) Map requirements to test cases and design elements C) Define coding standards D) Prioritize user stories Answer: B Explanation: Traceability ensures each requirement is linked to design, implementation, and verification artifacts. Question 5. Scope creep can be mitigated by: A) Accepting all change requests immediately B) Using a formal change control process C) Ignoring stakeholder feedback D) Extending the project deadline without analysis Answer: B Explanation: A change control process evaluates impact before approving requirement changes. Question 6. High cohesion in a module indicates that: A) The module performs many unrelated functions B) The module has a single, well-defined responsibility C) The module depends heavily on other modules D) The module is difficult to test Answer: B
Answer: A Explanation: The presentation layer is responsible for interacting with users. Question 10. Microservices architecture primarily promotes: A) Monolithic codebases B) Tight coupling between services C) Independent deployment of small, self-contained services D) Single point of failure Answer: C Explanation: Microservices are small services that can be deployed, scaled, and upgraded independently. Question 11. The Singleton design pattern ensures that: A) Multiple instances of a class can be created concurrently B) Only one instance of a class exists throughout the application lifecycle C) Objects are created lazily only when needed D) Subclasses share a common interface Answer: B Explanation: Singleton restricts instantiation to a single object. Question 12. Which pattern is best suited for defining a family of related objects without specifying their concrete classes? A) Factory Method B) Abstract Factory C) Builder D) Prototype Answer: B
Explanation: Abstract Factory provides an interface for creating families of related objects. Question 13. The Observer pattern is primarily used to: A) Encapsulate object creation B) Define a one-to-many dependency so that when one object changes, all dependents are notified C) Simplify complex object structures D) Separate algorithm from the object structure Answer: B Explanation: Observer enables automatic notification of dependent objects upon state changes. Question 14. In UML, which diagram best captures the dynamic behavior of objects over time? A) Class diagram B) Component diagram C) Sequence diagram D) Deployment diagram Answer: C Explanation: Sequence diagrams model interactions among objects in a time-ordered sequence. Question 15. A state machine diagram is most appropriate for modeling: A) Database schema B) Object hierarchy C) Life-cycle of an object with distinct states and transitions D) Network topology
D) Assertions guarantee program correctness in all environments Answer: B Explanation: Assertions check developer assumptions and can be turned off in release builds. Question 19. Incremental integration strategy differs from Big Bang integration by: A) Integrating all modules at once after development finishes B) Gradually adding and testing modules in small increments C) Avoiding any integration testing altogether D) Requiring a complete system rewrite before integration Answer: B Explanation: Incremental integration introduces modules step-by-step, reducing risk. Question 20. An API that follows the principle of “least astonishment” should: A) Require developers to read extensive documentation for each call B) Behave in a manner consistent with common developer expectations C) Use obscure naming conventions to hide complexity D) Force callers to manage low-level resources manually Answer: B Explanation: The principle of least astonishment ensures APIs act predictably. Question 21. Technical debt is best described as: A) Monetary cost incurred from licensing software B) The accumulated cost of shortcuts and sub-optimal design decisions that will require rework later
C) The amount of hardware resources a system consumes D) The number of bugs found during testing Answer: B Explanation: Technical debt represents future effort needed to fix or improve compromised code. Question 22. Verification in testing is concerned with: A) Ensuring the product meets user needs in real environments B) Checking that the software correctly implements its specifications C) Measuring performance under load D) Validating that the UI is aesthetically pleasing Answer: B Explanation: Verification asks “Did we build the system right?” – does implementation match specs? Question 23. Validation in testing focuses on: A) Ensuring the code compiles without errors B) Confirming that the software fulfills its intended purpose for the end user C) Checking internal logic paths D) Measuring code coverage percentages Answer: B Explanation: Validation asks “Did we build the right system?” – does it meet stakeholder needs? Question 24. Which of the following is a fault, an error, and a failure respectively? A) Incorrect algorithm, incorrect state, system crash B) System crash, incorrect algorithm, incorrect state
C) Exploratory testing D) Ad-hoc testing Answer: B Explanation: White-box (or structural) testing derives tests from code paths, branches, etc. Question 28. Boundary value analysis is most appropriate for testing: A) Textual content of a document B) Numeric input fields with defined limits C) System performance under load D) User interface layout Answer: B Explanation: Boundary value analysis focuses on values at, just below, and just above limits. Question 29. Equivalence partitioning reduces the number of test cases by: A) Testing every possible input value B) Grouping inputs that are expected to behave similarly and selecting representative values C) Ignoring invalid inputs D) Testing only the most extreme values Answer: B Explanation: Partitioning creates classes of equivalent inputs, so one test per class suffices. Question 30. Regression testing is essential because: A) It verifies new features only
B) It ensures that recent changes have not introduced defects into existing functionality C) It replaces all other test levels D) It is performed only once at project end Answer: B Explanation: Regression tests re-exercise previously working features after modifications. Question 31. Corrective maintenance is performed when: A) The operating system is upgraded B) Users request new features C) Bugs discovered after release need to be fixed D) Code is refactored for readability Answer: C Explanation: Corrective maintenance addresses defects in the operational system. Question 32. Adaptive maintenance is required when: A) Performance is optimized B) The software must operate on a new hardware platform or OS version C) New business rules are added D) Code is cleaned up for future changes Answer: B Explanation: Adaptive maintenance modifies the system to fit a changed environment. Question 33. Perfective maintenance focuses on:
Question 36. Tagging in a source-control system is typically used to: A) Mark a specific commit as a release or milestone B. Combine multiple branches into one C. Delete a set of files from the repository D. Automatically resolve merge conflicts Answer: A Explanation: Tags label a particular revision for reference, often for releases. Question 37. A baseline in configuration management represents: A) The most recent working copy of source code B) A formally reviewed and agreed-upon set of software artifacts at a point in time C. The initial project charter D. The daily build output Answer: B Explanation: Baselines freeze a set of artifacts for control and reference. Question 38. Configuration auditing ensures that: A. All developers have the same IDE settings B. The built product matches the documented configuration items and versions C. The code follows style guidelines D. The project budget is on track Answer: B Explanation: Auditing verifies that the actual system conforms to its configuration records.
Question 39. The Waterfall model is characterized by: A. Overlapping phases and iterative feedback loops B. Sequential phases where each must be completed before the next begins C. Continuous delivery of small increments D. No documentation requirements Answer: B Explanation: Waterfall follows a linear, phase-by-phase progression. Question 40. Agile Scrum defines a “Sprint” as: A. A long-term maintenance phase after release B. A time-boxed iteration usually lasting 2–4 weeks during which a potentially shippable product increment is created C. A meeting to discuss project budget D. The final testing phase of the project Answer: B Explanation: Sprints are fixed-length development cycles in Scrum. Question 41. In Kanban, work-in-progress (WIP) limits are used to: A. Increase the number of concurrent tasks B. Prevent overloading the team and highlight bottlenecks C. Ensure all tasks are completed at once D. Eliminate the need for daily stand-ups Answer: B Explanation: WIP limits cap the number of items in each column to improve flow. Question 42. Reliability as a quality attribute is measured by:
B. Be installed on a single server only C. Resist changes in business logic D. Increase its code size automatically Answer: A Explanation: Portable software can be transferred and operated across environments. Question 46. According to the IEEE/ACM Code of Ethics, a software engineer should: A. Prioritize personal profit over public safety B. Disclose any potential conflicts of interest that could affect professional judgment C. Keep all design decisions secret from clients D. Ignore user privacy concerns if they slow development Answer: B Explanation: The Code emphasizes integrity, including disclosure of conflicts. Question 47. The principle of “public interest” in professional ethics requires engineers to: A. Focus solely on employer’s profit goals B. Ensure that software does not cause harm to users or society C. Keep all source code proprietary D. Avoid collaborating with other engineers Answer: B Explanation: Public interest mandates that engineers protect health, safety, and welfare.
Question 48. Which of the following is a functional requirement for an online banking system? A. System must encrypt all data in transit using TLS 1. B. System must process a transaction within 2 seconds C. System must allow users to transfer funds between accounts D. System must be available 99.9% of the time annually Answer: C Explanation: Transferring funds describes a behavior the system must provide—functional. Question 49. A non-functional requirement that specifies “The system shall be usable by visually impaired users” is an example of: A. Performance attribute B. Security attribute C. Accessibility attribute (usability) D. Maintainability attribute Answer: C Explanation: Accessibility falls under usability, a non-functional quality. Question 50. During requirements analysis, a “conflict” between stakeholder A and stakeholder B is best resolved by: A. Ignoring the weaker stakeholder’s input B. Conducting a negotiation to find a compromise that satisfies the highest business value C. Deferring the decision to the development team D. Removing the conflicting requirement entirely Answer: B
Answer: C Explanation: Dependency Inversion states high-level modules should depend on abstractions. Question 54. The “Law of Demeter” (principle of least knowledge) advises developers to: A. Access only directly owned objects and avoid chaining calls to distant objects B. Use as many design patterns as possible C. Write code in a single massive class D. Share global variables across modules Answer: A Explanation: It reduces coupling by limiting knowledge of other objects. Question 55. In a layered architecture, which layer typically handles transaction management and security? A. Presentation layer B. Business logic layer C. Data access layer D. Infrastructure layer Answer: B Explanation: The business logic layer often encapsulates transactional and security concerns. Question 56. Event-driven architecture is most suitable for systems that: A. Require strict synchronous request-response communication only B. Need to react to asynchronous events and decouple producers from consumers
C. Have a single monolithic codebase D. Do not involve any user interaction Answer: B Explanation: Event-driven designs enable loose coupling via publish/subscribe mechanisms. Question 57. Which of the following is an example of a creational design pattern? A. Adapter B. Strategy C. Builder D. Mediator Answer: C Explanation: Builder constructs complex objects step by step. Question 58. The “Facade” pattern is primarily used to: A. Hide the complexities of a subsystem behind a simple interface B. Allow multiple inheritance in languages that don’t support it C. Create objects without specifying the exact class D. Manage concurrent access to shared resources Answer: A Explanation: Facade provides a unified high-level interface to a set of interfaces. Question 59. Which UML behavioral diagram captures the flow of activities and decision points within a process? A. State machine diagram