Skip to main content
  1. Resources/
  2. Study Materials/
  3. Information & Communication Technology Engineering/
  4. ICT Semester 5/

Software Engineering (4353202) - Winter 2024 Solution

19 mins· ·
Study-Material Solutions Software-Engineering 4353202 2024 Winter
Milav Dabgar
Author
Milav Dabgar
Experienced lecturer in the electrical and electronic manufacturing industry. Skilled in Embedded Systems, Image Processing, Data Science, MATLAB, Python, STM32. Strong education professional with a Master’s degree in Communication Systems Engineering from L.D. College of Engineering - Ahmedabad.
Table of Contents

Question 1(a) [3 marks]
#

Define software and explain its characteristics.

Answer:

Software is a collection of computer programs, procedures, and documentation that performs tasks on a computer system.

Table: Software Characteristics

CharacteristicDescription
IntangibleCannot be touched, only experienced
DevelopedEngineered, not manufactured
MaintainableCan be modified and updated
ReliableShould work consistently
EfficientUses resources optimally
  • Key point: Software = Programs + Documentation + Procedures
  • Mnemonic: “I Don’t Make Reliable Electronics” (Intangible, Developed, Maintainable, Reliable, Efficient)

Question 1(b) [4 marks]
#

Explain classical waterfall model.

Answer:

Waterfall Model is a linear sequential software development approach where each phase must be completed before the next begins.

graph TD
    A[Requirements Analysis] --> B[System Design]
    B --> C[Implementation]
    C --> D[Testing]
    D --> E[Deployment]
    E --> F[Maintenance]

Key Features:

  • Sequential phases: No overlap between phases
  • Documentation-driven: Heavy documentation at each phase
  • Simple structure: Easy to understand and manage
  • Fixed requirements: Changes are difficult once started

Mnemonic: “Real Systems Include Testing, Deployment, Maintenance”


Question 1(c) [7 marks]
#

Explain software process framework and umbrella activities.

Answer:

Software Process Framework provides the foundation for complete software engineering process by identifying key process areas.

graph LR
    A[Communication] --> B[Planning]
    B --> C[Modeling]
    C --> D[Construction]
    D --> E[Deployment]
    E --> A
    
    F[Umbrella Activities] --> A
    F --> B
    F --> C
    F --> D
    F --> E

Table: Framework Activities vs Umbrella Activities

Framework ActivitiesUmbrella Activities
CommunicationSoftware project tracking
PlanningRisk management
ModelingQuality assurance
ConstructionTechnical reviews
DeploymentConfiguration management

Framework Activities:

  • Communication: Gather requirements from stakeholders
  • Planning: Create project plan and schedule
  • Modeling: Create design models
  • Construction: Code generation and testing
  • Deployment: Software delivery and feedback

Umbrella Activities run throughout the project:

  • Project tracking: Monitor progress
  • Risk management: Identify and control risks
  • Quality assurance: Ensure quality standards
  • Configuration management: Control changes

Mnemonic: “Can People Make Construction Deploy” (Communication, Planning, Modeling, Construction, Deployment)


Question 1(c) OR [7 marks]
#

Write a short note on SCRUM.

Answer:

SCRUM is an agile framework for managing software development projects using iterative and incremental practices.

graph TD
    A[Product Backlog] --> B[Sprint Planning]
    B --> C[Sprint Backlog]
    C --> D[Sprint 2-4 weeks]
    D --> E[Sprint Review]
    E --> F[Sprint Retrospective]
    F --> B
    D --> G[Daily Scrum]
    G --> D

Table: SCRUM Roles and Artifacts

ComponentDescription
Product OwnerDefines requirements and priorities
Scrum MasterFacilitates process and removes obstacles
Development TeamSelf-organizing team that builds product
Product BacklogPrioritized list of features
Sprint BacklogTasks selected for current sprint

Key Events:

  • Sprint Planning: Select work for upcoming sprint
  • Daily Scrum: 15-minute daily synchronization
  • Sprint Review: Demonstrate completed work
  • Sprint Retrospective: Reflect and improve process

Benefits: Fast delivery, flexibility, continuous improvement, customer collaboration

Mnemonic: “People Sprint Daily Reviewing Retrospectively”


Question 2(a) [3 marks]
#

Explain characteristic of good SRS.

Answer:

SRS (Software Requirements Specification) document should have specific qualities to be effective.

Table: Good SRS Characteristics

CharacteristicMeaning
CompleteAll requirements included
ConsistentNo contradictory requirements
UnambiguousClear and single interpretation
VerifiableCan be tested and validated
ModifiableEasy to change when needed
  • Complete: Contains all functional and non-functional requirements
  • Consistent: No conflicts between different requirements
  • Unambiguous: Each requirement has only one interpretation

Mnemonic: “Complete Computers Use Verified Modifications”


Question 2(b) [4 marks]
#

Describe advantage and disadvantages of prototype model.

Answer:

Prototype Model creates a working model of software to understand requirements better.

Table: Prototype Model - Pros and Cons

AdvantagesDisadvantages
Better requirement understandingTime consuming
User involvementCost increase
Early error detectionIncomplete analysis
User satisfactionPrototype confusion

Advantages:

  • Clear requirements: Users see working model
  • Early feedback: Reduces final product risks
  • User involvement: Better user acceptance

Disadvantages:

  • Extra time: Building prototype takes time
  • Additional cost: Resources needed for prototype
  • Scope creep: Users may expect prototype features

Mnemonic: “Better Users Experience” vs “Time Costs Increase”


Question 2(c) [7 marks]
#

Design and describe Spiral model and give advantages and disadvantages.

Answer:

Spiral Model combines iterative development with systematic risk management through repeated cycles.

graph TD
    A[Planning] --> B[Risk Analysis]
    B --> C[Engineering]
    C --> D[Customer Evaluation]
    D --> A
    
    E[Quadrant 1: Planning] 
    F[Quadrant 2: Risk Analysis]
    G[Quadrant 3: Engineering]
    H[Quadrant 4: Customer Evaluation]

Table: Spiral Model Phases

PhaseActivities
PlanningRequirements gathering, resource planning
Risk AnalysisIdentify and resolve risks
EngineeringDevelopment and testing
Customer EvaluationCustomer reviews and feedback

Advantages:

  • Risk management: Early risk identification
  • Flexibility: Accommodates changes easily
  • Customer involvement: Regular customer feedback
  • Quality focus: Continuous testing and validation

Disadvantages:

  • Complex management: Difficult to manage
  • High cost: Expensive due to risk analysis
  • Time consuming: Long development cycles
  • Risk expertise needed: Requires risk assessment skills

Best for: Large, complex, high-risk projects

Mnemonic: “Plan Risks Engineering Customer” for phases


Question 2(a) OR [3 marks]
#

Explain Incremental model.

Answer:

Incremental Model delivers software in small, functional pieces called increments.

graph LR
    A[Core Product] --> B[Increment 1]
    B --> C[Increment 2]
    C --> D[Increment 3]
    D --> E[Final Product]

Key Features:

  • Partial implementation: Each increment adds functionality
  • Early delivery: Core features delivered first
  • Parallel development: Multiple increments can be developed simultaneously

Table: Incremental Model Characteristics

AspectDescription
DeliveryMultiple releases
FunctionalityGrows with each increment
RiskReduced through early delivery
FeedbackContinuous user feedback

Mnemonic: “Deliver Functionality Reducing Feedback”


Question 2(b) OR [4 marks]
#

Write concept of Rapid Application Development model and explain it.

Answer:

RAD (Rapid Application Development) emphasizes rapid prototyping and quick feedback over extensive planning.

Table: RAD Model Phases

PhaseDurationActivities
Business ModelingShortDefine business functions
Data ModelingShortDefine data requirements
Process ModelingShortConvert data to business info
Application GenerationShortUse tools to create software
Testing & TurnoverShortTest and deploy

Key Concepts:

  • Reusable components: Pre-built components speed development
  • Powerful tools: CASE tools and code generators
  • Small teams: 2-6 people per team
  • Time-boxed: Strict time limits (60-90 days)

Requirements for RAD:

  • Well-defined business requirements
  • User involvement throughout process
  • Skilled developers familiar with RAD tools

Mnemonic: “Business Data Process Application Testing”


Question 2(c) OR [7 marks]
#

Define SDLC and explain each phase.

Answer:

SDLC (Software Development Life Cycle) is a systematic process for building software through well-defined phases.

graph TD
    A[Planning] --> B[Analysis]
    B --> C[Design]
    C --> D[Implementation]
    D --> E[Testing]
    E --> F[Deployment]
    F --> G[Maintenance]
    G --> A

Table: SDLC Phases Detailed

PhaseActivitiesDeliverables
PlanningProject planning, feasibility studyProject plan
AnalysisRequirement gatheringSRS document
DesignSystem architecture, UI designDesign document
ImplementationCoding, unit testingSource code
TestingSystem testing, integrationTest reports
DeploymentInstallation, user trainingLive system
MaintenanceBug fixes, enhancementsUpdated system

Phase Descriptions:

  • Planning: Define project scope and resources
  • Analysis: Understand what system should do
  • Design: Plan how system will work
  • Implementation: Build the actual system
  • Testing: Verify system works correctly
  • Deployment: Release system to users
  • Maintenance: Ongoing support and updates

Mnemonic: “People Always Design Implementation, Test Deployment, Maintain”


Question 3(a) [3 marks]
#

Describe skills to manage software projects.

Answer:

Software Project Management requires combination of technical and soft skills.

Table: Essential Project Management Skills

Skill CategorySpecific Skills
TechnicalUnderstanding SDLC, tools, technologies
LeadershipTeam motivation, decision making
CommunicationClear communication with team and clients
PlanningResource allocation, scheduling
Problem-solvingRisk management, conflict resolution

Key Skills:

  • People management: Lead and motivate team members
  • Technical knowledge: Understand development process and tools
  • Communication: Bridge between technical team and stakeholders

Mnemonic: “Technical Leaders Communicate Planning Problems”


Question 3(b) [4 marks]
#

Briefly write responsibility of Software Project manager.

Answer:

Software Project Manager oversees entire project from initiation to completion.

Table: Project Manager Responsibilities

AreaResponsibilities
PlanningCreate project plans, schedules, budgets
Team ManagementHire, train, and manage team members
CommunicationRegular updates to stakeholders
Quality ControlEnsure deliverables meet quality standards
Risk ManagementIdentify and mitigate project risks

Primary Responsibilities:

  • Project Planning: Define scope, timeline, and resources
  • Team Leadership: Guide and support development team
  • Stakeholder Communication: Keep everyone informed of progress
  • Quality Assurance: Ensure project meets requirements
  • Risk Management: Handle project risks and issues

Success Factors: On-time delivery, within budget, meeting requirements

Mnemonic: “Plan Team Communication Quality Risk”


Question 3(c) [7 marks]
#

Classify types of Requirements in SRS (1) Functional Requirements (2) Non-Functional Requirements.

Answer:

Requirements Classification helps organize and understand different types of system needs.

Table: Functional vs Non-Functional Requirements

AspectFunctional RequirementsNon-Functional Requirements
DefinitionWhat system should doHow system should perform
FocusSystem functionalitySystem quality attributes
ExamplesLogin, search, calculatePerformance, security, usability
TestingFunctional testingPerformance testing

Functional Requirements:

  • User interactions: Login, registration, data entry
  • Business rules: Validation rules, calculations
  • System features: Reports, notifications, workflows
  • Data processing: CRUD operations

Examples:

  • User can login with username/password
  • System calculates tax automatically
  • Generate monthly sales report

Non-Functional Requirements:

Table: Non-Functional Requirement Types

TypeDescriptionExample
PerformanceSpeed and responsivenessResponse time < 2 seconds
SecurityData protectionEncrypted data transmission
UsabilityUser experienceEasy to learn interface
ReliabilitySystem dependability99.9% uptime
ScalabilityGrowth handlingSupport 1000+ users

Quality Attributes:

  • Performance: Response time, throughput
  • Security: Authentication, authorization, encryption
  • Usability: User-friendly interface, accessibility
  • Reliability: Uptime, error handling
  • Maintainability: Code quality, documentation

Mnemonic: “Performance Security Usability Reliability Maintainability”


Question 3(a) OR [3 marks]
#

Illustrate importance of SRS.

Answer:

SRS (Software Requirements Specification) is crucial document that defines what software should do.

Table: SRS Importance

AspectBenefit
Clear CommunicationAll stakeholders understand requirements
Project PlanningBasis for estimation and scheduling
Quality AssuranceFoundation for testing
Change ManagementControlled requirement changes
Legal ProtectionContract reference document

Key Importance:

  • Communication tool: Bridge between clients and developers
  • Planning foundation: Helps estimate time, cost, and resources
  • Testing basis: Test cases derived from SRS requirements

Mnemonic: “Clear Planning Quality Change Legal”


Question 3(b) OR [4 marks]
#

Explain Gantt Chart.

Answer:

Gantt Chart is a visual project management tool showing tasks, timelines, and dependencies.

gantt
    title Project Schedule
    dateFormat  YYYY-MM-DD
    section Phase 1
    Requirements    :a1, 2024-01-01, 30d
    Design         :a2, after a1, 20d
    section Phase 2
    Coding         :a3, after a2, 45d
    Testing        :a4, after a3, 15d

Table: Gantt Chart Components

ComponentDescription
TasksWork items to be completed
TimelineHorizontal time scale
BarsTask duration and progress
DependenciesTask relationships
MilestonesImportant project events

Benefits:

  • Visual timeline: Easy to see project schedule
  • Progress tracking: Monitor task completion
  • Resource planning: Allocate resources effectively
  • Dependency management: Understand task relationships

Mnemonic: “Tasks Timeline Bars Dependencies Milestones”


Question 3(c) OR [7 marks]
#

Write a short note on Risk Management.

Answer:

Risk Management is systematic process of identifying, analyzing, and controlling project risks.

graph TD
    A[Risk Identification] --> B[Risk Analysis]
    B --> C[Risk Planning]
    C --> D[Risk Monitoring]
    D --> A

Table: Risk Management Process

PhaseActivitiesOutput
IdentificationFind potential risksRisk list
AnalysisAssess probability and impactRisk priority
PlanningDevelop response strategiesRisk response plan
MonitoringTrack and control risksUpdated risk status

Risk Categories:

Table: Types of Software Risks

CategoryExamples
TechnicalTechnology changes, complexity
ProjectSchedule delays, resource shortage
BusinessMarket changes, funding issues
ExternalVendor problems, regulatory changes

Risk Response Strategies:

  • Avoid: Eliminate risk source
  • Mitigate: Reduce probability or impact
  • Transfer: Share risk with others
  • Accept: Live with the risk

Risk Assessment: Probability × Impact = Risk Exposure

Benefits: Proactive problem solving, better project success rate, stakeholder confidence

Mnemonic: “Identify Analyze Plan Monitor” for process, “Avoid Mitigate Transfer Accept” for strategies


Question 4(a) [3 marks]
#

What is metric for size estimation? Explain FP with example.

Answer:

Size Estimation Metrics help predict software project size and effort.

Table: Size Estimation Metrics

MetricDescription
LOCLines of Code
Function PointsFunctionality-based measurement
Object PointsFor object-oriented systems
Feature PointsEnhanced function points

Function Points (FP) measure software size based on user functionality.

FP Components:

  • External Inputs: Data entry screens
  • External Outputs: Reports, messages
  • External Queries: Database queries
  • Internal Files: Data stores
  • External Interfaces: System connections

FP Calculation Example: For a Library Management System:

  • External Inputs: 5 (Book entry, Member entry, etc.)
  • External Outputs: 3 (Reports)
  • External Queries: 4 (Search functions)
  • Internal Files: 2 (Book DB, Member DB)
  • External Interfaces: 1 (Online catalog)

Simple FP = 5 + 3 + 4 + 2 + 1 = 15 Function Points

Mnemonic: “Inputs Outputs Queries Files Interfaces”


Question 4(b) [4 marks]
#

Explain project estimation techniques using basic COCOMO model.

Answer:

COCOMO (COnstructive COst MOdel) estimates software development effort and schedule.

Table: COCOMO Model Types

TypeDescriptionAccuracy
BasicSimple size-based estimation±75%
IntermediateIncludes cost drivers±25%
DetailedPhase-level estimation±10%

Basic COCOMO Formula:

  • Effort = a × (KLOC)^b person-months
  • Time = c × (Effort)^d months
  • People = Effort / Time

Table: COCOMO Constants

Project Typeabcd
Organic2.41.052.50.38
Semi-detached3.01.122.50.35
Embedded3.61.202.50.32

Example: For 10 KLOC organic project

  • Effort = 2.4 × (10)^1.05 = 25.47 person-months
  • Time = 2.5 × (25.47)^0.38 = 8.64 months
  • People = 25.47 / 8.64 = 3 people

Mnemonic: “Organic Semi Embedded” for project types


Question 4(c) [7 marks]
#

Prepare Sprint burn down chart for system of your choice.

Answer:

Sprint Burn Down Chart tracks remaining work during a sprint for Online Shopping System.

graph LR
    A[Sprint Goal: User Authentication Module<br/>Sprint Duration: 2 weeks<br/>Total Story Points: 40]

Sprint Backlog:

Table: Sprint Tasks

TaskStory PointsDay Assigned
User Registration8Day 1-2
User Login6Day 3-4
Password Reset5Day 5-6
Profile Management8Day 7-8
Session Management6Day 9-10
Testing & Bug Fixes7Day 11-14

Burn Down Chart Data:

Table: Daily Progress

DayIdeal RemainingActual RemainingWork Completed
Day 04040Sprint Start
Day 23638Registration delay
Day 43232Login completed
Day 62827Password reset done early
Day 82426Profile management issues
Day 102020Back on track
Day 121615Testing progressing well
Day 1400Sprint completed

Chart Analysis:

  • Green line: Ideal burn down
  • Red line: Actual progress
  • Variations: Show challenges and recoveries
  • Completion: Sprint finished on time

Benefits: Visual progress tracking, early problem identification, team motivation

Mnemonic: “Track Progress Daily, Identify Issues Early”


Question 4(a) OR [3 marks]
#

Explain the component of USE CASE diagram.

Answer:

Use Case Diagram shows system functionality from user perspective.

Table: Use Case Diagram Components

ComponentSymbolDescription
ActorStick figureExternal entity interacting with system
Use CaseOvalSystem functionality
System BoundaryRectangleSystem scope
AssociationLineActor-Use Case relationship
GeneralizationArrowInheritance relationship

Relationships:

  • Include: One use case includes another (mandatory)
  • Extend: Optional use case extension
  • Generalization: Parent-child relationship

Example Components:

  • Primary Actor: Customer, Admin
  • Use Cases: Login, Search Products, Place Order
  • System: Online Shopping System

Mnemonic: “Actors Use Systems, Associate Generally”


Question 4(b) OR [4 marks]
#

Compare Cohesion and Coupling.

Answer:

Cohesion and Coupling are important software design principles affecting maintainability.

Table: Cohesion vs Coupling Comparison

AspectCohesionCoupling
DefinitionUnity within moduleDependency between modules
Desirable LevelHigh cohesion preferredLow coupling preferred
FocusInternal module unityInter-module relationships
ImpactModule reliabilitySystem flexibility
MeasurementHow related are module elementsHow dependent modules are

Cohesion Types (Low to High):

  • Coincidental: Random grouping
  • Logical: Similar logic
  • Temporal: Same time execution
  • Procedural: Sequential steps
  • Communicational: Same data
  • Sequential: Output of one is input of next
  • Functional: Single purpose

Coupling Types (High to Low):

  • Content: Direct access to module internals
  • Common: Shared global data
  • External: Shared external interface
  • Control: Control information passed
  • Stamp: Data structure passed
  • Data: Simple data passed

Goal: High Cohesion + Low Coupling = Good Design

Mnemonic: “High Cohesion, Low Coupling” for good design


Question 4(c) OR [7 marks]
#

Explain Risk Assessment in detail.

Answer:

Risk Assessment evaluates identified risks to prioritize management efforts.

graph TD
    A[Risk Identification] --> B[Risk Assessment]
    B --> C[Probability Analysis]
    B --> D[Impact Analysis]
    C --> E[Risk Exposure Calculation]
    D --> E
    E --> F[Risk Prioritization]

Risk Assessment Components:

Table: Risk Assessment Elements

ElementDescriptionScale
ProbabilityLikelihood of risk occurring0.1 to 1.0
ImpactConsequences if risk occurs1 to 10
Risk ExposureProbability × ImpactCalculated value
Risk LevelPriority classificationHigh/Medium/Low

Assessment Process:

1. Probability Assessment:

  • Very Low (0.1): Unlikely to happen
  • Low (0.3): Possible but not probable
  • Medium (0.5): May or may not happen
  • High (0.7): Likely to happen
  • Very High (0.9): Almost certain

2. Impact Assessment:

  • Catastrophic (9-10): Project failure
  • Critical (7-8): Major delays/cost overrun
  • Marginal (4-6): Some impact on schedule/budget
  • Negligible (1-3): Little impact

3. Risk Exposure Calculation: Risk Exposure = Probability × Impact

Example Risk Assessment:

Table: Sample Risk Analysis

RiskProbabilityImpactExposurePriority
Key developer leaves0.382.4Medium
Requirements change0.764.2High
Technology failure0.291.8Low
Budget cuts0.472.8Medium

Risk Matrix:

  • High Priority: Exposure > 4.0
  • Medium Priority: Exposure 2.0-4.0
  • Low Priority: Exposure < 2.0

Assessment Benefits:

  • Objective prioritization: Data-driven decisions
  • Resource allocation: Focus on high-risk items
  • Communication tool: Clear risk communication
  • Planning input: Influences project planning

Mnemonic: “Probability Impact Exposure Priority”


Question 5(a) [3 marks]
#

Explain code inspection technique in code review.

Answer:

Code Inspection is formal, systematic examination of code to find defects.

Table: Code Inspection Process

PhaseParticipantsActivities
PlanningModeratorSchedule inspection, distribute code
OverviewAuthor, TeamAuthor explains code
PreparationIndividualEach reviewer studies code
InspectionAll reviewersFind defects systematically
ReworkAuthorFix identified defects
Follow-upModeratorVerify fixes

Key Features:

  • Formal process: Structured approach with defined roles
  • Systematic review: Line-by-line examination
  • Defect focused: Find errors, not solutions
  • No author criticism: Focus on code, not coder

Benefits: Early defect detection, knowledge sharing, improved code quality

Mnemonic: “Plan Overview Prepare Inspect Rework Follow-up”


Question 5(b) [4 marks]
#

Prepare at least four test cases of ATM.

Answer:

ATM Test Cases verify automated teller machine functionality.

Table: ATM Test Cases

Test Case IDTest ScenarioInputExpected OutputResult
TC001Valid PIN EntryCorrect 4-digit PINAccess granted, main menu displayedPass/Fail
TC002Invalid PIN EntryWrong PIN (3 attempts)Card blocked, error messagePass/Fail
TC003Cash WithdrawalAmount ≤ Account balanceCash dispensed, receipt printedPass/Fail
TC004Insufficient BalanceAmount > Account balanceTransaction declined, balance shownPass/Fail

Detailed Test Cases:

Test Case 1: Valid Login

  • Precondition: ATM is operational, card inserted
  • Steps: Enter correct PIN → Press Enter
  • Expected: Main menu with options displayed

Test Case 2: Cash Withdrawal

  • Precondition: User logged in, sufficient balance
  • Steps: Select Withdrawal → Enter amount → Confirm
  • Expected: Cash dispensed, balance updated

Test Case 3: Balance Inquiry

  • Precondition: User logged in
  • Steps: Select Balance Inquiry
  • Expected: Current balance displayed on screen

Test Case 4: PIN Change

  • Precondition: User logged in
  • Steps: Select Change PIN → Enter old PIN → Enter new PIN → Confirm
  • Expected: PIN changed successfully, confirmation message

Mnemonic: “Login Withdraw Inquiry Change”


Question 5(c) [7 marks]
#

Describe white box testing.

Answer:

White Box Testing examines internal code structure and logic paths.

graph TD
    A[Source Code] --> B[Control Flow Analysis]
    B --> C[Path Coverage]
    C --> D[Test Case Design]
    D --> E[Test Execution]
    E --> F[Coverage Analysis]

Table: White Box Testing Characteristics

AspectDescription
FocusInternal code structure
KnowledgeCode implementation details
CoverageStatements, branches, paths
TechniquesBasis path, loop testing
ToolsCode coverage analyzers

Coverage Criteria:

Table: Coverage Types

Coverage TypeDescriptionGoal
Statement CoverageExecute every statement100% statements
Branch CoverageExecute every branchAll if-else paths
Path CoverageExecute every pathAll possible paths
Condition CoverageTest all conditionsTrue/false for each condition

White Box Testing Techniques:

1. Basis Path Testing:

  • Calculate Cyclomatic Complexity: V(G) = E - N + 2
  • E = Edges, N = Nodes in control flow graph
  • Generate independent paths equal to V(G)

2. Loop Testing:

  • Simple loops: Test 0, 1, 2, typical, max iterations
  • Nested loops: Test inner loop first, then outer
  • Concatenated loops: Test as separate loops

3. Condition Testing:

  • Test all logical conditions (AND, OR, NOT)
  • Ensure each condition evaluates to true and false

Example: Simple Code Testing

if (age >= 18 AND income > 25000)
    approve_loan();
else
    reject_loan();

Test Cases:

  • age=20, income=30000 (both true) → approve
  • age=16, income=30000 (first false) → reject
  • age=20, income=20000 (second false) → reject
  • age=16, income=20000 (both false) → reject

Advantages:

  • Thorough testing: Tests internal logic
  • Early defect detection: Finds logic errors
  • Coverage measurement: Quantifiable testing progress

Disadvantages:

  • Time consuming: Requires code knowledge
  • Expensive: Needs skilled testers
  • Maintenance: Changes with code updates

Tools: JUnit (Java), NUnit (.NET), Coverage.py (Python)

Mnemonic: “Statement Branch Path Condition” for coverage types


Question 5(a) OR [3 marks]
#

Explain code walk through Technique in code review.

Answer:

Code Walk Through is informal code review technique where author presents code to team.

Table: Walk Through Process

PhaseDescriptionDuration
PreparationAuthor prepares presentation30 minutes
PresentationAuthor explains code logic1-2 hours
DiscussionTeam asks questions, suggests improvements30 minutes
DocumentationRecord issues and action items15 minutes

Key Characteristics:

  • Author-led: Code author drives the session
  • Informal process: Less structured than inspection
  • Educational: Team learns about code functionality
  • Collaborative: Open discussion encouraged

Participants:

  • Author: Presents and explains code
  • Reviewers: Ask questions and provide feedback
  • Moderator: Keeps discussion focused (optional)

Benefits: Knowledge sharing, early problem detection, team collaboration, learning opportunity

Mnemonic: “Prepare Present Discuss Document”


Question 5(b) OR [4 marks]
#

Explain software documentation.

Answer:

Software Documentation provides information about software system for various stakeholders.

Table: Documentation Types

TypePurposeAudience
User DocumentationHow to use softwareEnd users
System DocumentationTechnical detailsDevelopers, maintainers
Process DocumentationDevelopment processProject team
Requirements DocumentationWhat system should doAll stakeholders

Internal Documentation:

  • Code comments: Explain complex logic
  • Function headers: Describe purpose and parameters
  • Variable names: Self-documenting identifiers
  • README files: Project overview and setup

External Documentation:

  • User manuals: Step-by-step usage instructions
  • Installation guides: Setup procedures
  • API documentation: Interface specifications
  • Training materials: Educational content

Benefits:

  • Maintainability: Easier code updates
  • Knowledge transfer: New team members learn faster
  • User support: Reduces support requests
  • Quality assurance: Documents requirements and design

Documentation Standards: Consistent format, regular updates, version control, accessibility

Mnemonic: “User System Process Requirements” for types


Question 5(c) OR [7 marks]
#

Write a short note on black box testing.

Answer:

Black Box Testing examines software functionality without knowledge of internal code structure.

graph LR
    A[Input] --> B[Software System<br/>Black Box] --> C[Output]
    D[Test Cases] --> A
    E[Expected Results] --> F[Compare]
    C --> F

Table: Black Box Testing Characteristics

AspectDescription
FocusExternal behavior
KnowledgeRequirements and specifications
ApproachInput-output relationship
CoverageFunctional requirements
PerspectiveUser viewpoint

Black Box Testing Techniques:

Table: Testing Techniques

TechniqueDescriptionExample
Equivalence PartitioningDivide inputs into valid/invalid classesAge: 0-17, 18-65, >65
Boundary Value AnalysisTest at boundariesTest age: 17, 18, 65, 66
Decision TableComplex business rulesInsurance premium calculation
State TransitionSystem state changesATM states: idle, processing, error

1. Equivalence Partitioning:

  • Valid partitions: Accepted inputs
  • Invalid partitions: Rejected inputs
  • Test one value from each partition

Example: Password length (6-12 characters)

  • Valid: 6-12 characters
  • Invalid: <6 characters, >12 characters

2. Boundary Value Analysis:

  • Test minimum, maximum, just below minimum, just above maximum
  • Most errors occur at boundaries

Example: For range 1-100

  • Test: 0, 1, 2, 99, 100, 101

3. Decision Table Testing:

  • Conditions: Input conditions
  • Actions: Expected outputs
  • Rules: Condition-action combinations

Advantages:

  • User perspective: Tests from user viewpoint
  • No code knowledge needed: Testers don’t need programming skills
  • Unbiased: Not influenced by code implementation
  • Early testing: Can start with requirements

Disadvantages:

  • Limited coverage: May miss some code paths
  • Redundant testing: Might test same logic multiple times
  • Difficult test case design: Hard without internal knowledge

Types of Black Box Testing:

  • Functional Testing: Core functionality
  • Non-functional Testing: Performance, usability
  • Regression Testing: After changes
  • User Acceptance Testing: Final validation

Tools: Selenium (web), Appium (mobile), TestComplete, QTP

When to Use:

  • System testing phase
  • User acceptance testing
  • Integration testing
  • Regression testing

Mnemonic: “Equivalence Boundary Decision State” for techniques

Related

OOPS & Python Programming (4351108) - Winter 2024 Solution
20 mins
Study-Material Solutions Python Oops 4351108 2024 Winter
Renewable Energy & Emerging Trends in Electronics (4361106) - Winter 2024 Solution
40 mins
Study-Material Solutions Renewable-Energy 4361106 2024 Winter
Java Programming (4343203) - Winter 2024 Solution
27 mins
Study-Material Solutions Java-Programming 4343203 2024 Winter
Embedded System & Microcontroller Application (4351102) - Winter 2024 Solution
19 mins
Study-Material Solutions Embedded-System 4351102 2024 Winter
VLSI (4361102) - Winter 2024 Solution
16 mins
Study-Material Solutions Vlsi 4361102 2024 Winter
Wireless Sensor Networks and IoT (4353201) - Winter 2024 Solution
21 mins
Study-Material Solutions Wireless-Sensor-Networks Iot 4353201 2024 Winter