SEN2022 · Week 9 · Midterm Exam

Midterm review: weeks 1-8

SDLC, feasibility calculations, function points, critical path, requirements, use cases and class diagrams on a single page. Mixed midterm questions at the end.

SDLCsystem proposalNPVROIpayback periodfunction pointAPCcritical pathslackfunctional requirementnonfunctional requirementincludeextendmultiplicitycompositionaggregationuse case description

The midterm covers weeks 1-8. The distribution of questions is usually like this: a few definition and multiple-choice questions (SDLC, methodology, types of feasibility, types of requirements), one or two calculations (NPV/ROI/payback, function points, critical path), one drawing (a use case diagram or class diagram) and one writing task (a use case description). This page collects the essence of each topic in a table, then tests you with mixed questions. First read the tables, then solve the questions without looking at the answers.

Topic map

WeekTopicHow it appears on the exam
1SDLC, analyst roles, methodologiesDefinitions, the “which methodology” scenario
2System request, feasibilityNPV, ROI, payback calculation; type of feasibility
3Project management, function points, scopeFP calculation, definition of timeboxing/scope creep
4Problem analysis, Gantt, PERT/CPMCritical path and slack calculation, PIECES
5Requirements and techniquesRequirement classification, choice of technique
6Use case diagramExtract actors and use cases from a scenario, draw
7Use case descriptionWrite a fully dressed one
8CRC, class and object diagramDraw a class diagram from a scenario, multiplicity

Checklist for calculation questions

Feasibility (week 2)

  1. Build a table with the years as columns: benefit, cost, net, PV, cumulative.
  2. Year 0 is not discounted.
  3. NPV is written with the currency, ROI as a percentage, payback in years.
  4. In payback, divide by the crossover year’s own flow.

PV=F(1+r)tROI=B−CCPV = \frac{F}{(1+r)^t} \qquad ROI = \frac{B - C}{C}

Function points (week 3)

TUFP = Σ (count x weight)
APC  = 0.65 + 0.01 x PC      (PC: 0..70)
AFP  = TUFP x APC
LOC  = AFP x lines/FP
effort = 1.4 x KLOC            (person-months)
schedule = 3.0 x effort^(1/3)  (months)
LowAvgHigh
EI346
EO457
EQ346
ILF71015
EIF5710

CPM (week 4)

Forward : ES = max(predecessor EF), EF = ES + d
Backward: LF = min(successor LS), LS = LF - d
Slack = LS - ES
Critical path: slack = 0, the longest path
Check: the length of the critical path = project duration

Comparison tables for concept questions

Methodologies

SituationSuitable
Requirements clear and fixed, documentation mandatoryWaterfall, V-model
Requirements unclear, the user understands when they see itSystem prototyping, agile
High technical risk, unclear requirementsThrowaway prototyping
Short schedule, priority parts firstIterative, timeboxing, Scrum
Large, OO, with UMLUnified Process

Requirements gathering

NeedTechnique
Deep, detailed informationInterview
Many people, cheap, broadQuestionnaire
Real behaviorObservation
Formal rules, formsDocument analysis
Joint decision, resolving conflictJAD

Use case relationships

RelationshipWhenArrow
IncludeShared part that runs every timeBase → included
ExtendConditional additional behaviorExtending → base
GeneralizationSpecial kindChild → parent, hollow triangle

Class diagram relationships

RelationshipSentenceSymbol
Association”… is related to”Solid line
Aggregation“has a”, the part is independentHollow diamond at the whole
Composition“is part of”, the part dies with the wholeFilled diamond at the whole
Generalization“is a kind of”Hollow triangle at the superclass

Strategy for drawing questions

  1. List first, then draw. Write the actor/use case or class/attribute table on the side. When you move to the drawing you won’t forget anything.
  2. Mark every sentence in the scenario. Every sentence should correspond to at least one element. If a sentence is left unused, you missed something.
  3. Don’t leave multiplicity for last. The moment you draw each relationship, ask two questions: “How many B does one A have?” and “How many A does one B have?”
  4. Draw legibly. Lines should not cross; reposition the classes if necessary.

Use case description strategy

Write the template from memory: name, ID, importance, primary actor, stakeholders and interests, brief description, trigger (type), relationships, preconditions, normal flow, subflows, alternate/exceptional flows, postconditions. The normal flow should have 5-8 steps, each step starting with “The student …” or “The system …”. Write at least two alternate flows and state the return point.

Common mistakes (whole semester)

WrongRight
The system proposal is the output of designIt is the output of analysis
Discounting year 0The factor for year 0 is 1
APC = 0.65 × PCAPC = 0.65 + 0.01 × PC
Max in the backward passMin in the backward pass
A performance requirement is functionalNonfunctional
The extend arrow from the baseFrom the extending one to the base
Multiplicity at its own endRead from the opposite end
The diamond on the part sideOn the whole side

Test yourself

Exam-style questions. Solve them on paper first, then reveal the answer.

Question 1easy

Which SDLC phase produces the system specification?

  1. Planning
  2. Analysis
  3. Design
  4. Implementation
Show answer
C) Design

Planning → system request + feasibility + plan. Analysis → system proposal. Design → system specification. Implementation → the installed, working system.

Question 2hard

A project costs 60,000 TL and yields 25,000 TL net per year for 3 years. At 12%, what is the NPV?

Show answer
≈ 46 TL (45.78 TL)

PVs: 25000/1.12=22321.4325000/1.12 = 22321.43, 25000/1.122=19929.8525000/1.12^2 = 19929.85, 25000/1.123=17794.5125000/1.12^3 = 17794.51. Total 60,045.78. NPV = 60,045.78 − 60,000 = 45.78 TL. Positive but marginal: if the discount rate rose a little, the project would turn negative. Although the nominal total is 75,000, the real gain is almost zero.

Question 3medium

Same project: what is the simple payback period and the nominal ROI?

Show answer
Payback 2.4 years, ROI 25%

Cumulative: −35,000, −10,000, +15,000. Payback = 2 + 10,000/25,000 = 2.4 years. ROI = (75,000 − 60,000) / 60,000 = 0.25 = 25%.

Question 4medium

Counts: EI 4 low and 3 high; EO 2 average; EQ 3 low; ILF 2 low; EIF 1 high. PC = 40. Find TUFP and adjusted FP.

Show answer
TUFP 73, AFP 76.65

EI: 4×3 + 3×6 = 30. EO: 2×5 = 10. EQ: 3×3 = 9. ILF: 2×7 = 14. EIF: 1×10 = 10. TUFP = 73. APC = 0.65 + 0.40 = 1.05. AFP = 73 × 1.05 = 76.65.

Question 5medium

Tasks (days, predecessors): A 3 (none), B 2 (A), C 4 (A), D 3 (B, C), E 1 (D). Give the critical path, the duration and the slack of B.

Show answer
A-C-D-E, 11 days, slack of B = 2

Forward pass: A 0-3, B 3-5, C 3-7, D max(5,7)=7 → 10, E 10-11. Duration 11.
Backward pass: E LS 10, D LF 10 LS 7, B LF 7 LS 5, C LF 7 LS 3, A LF min(5,3)=3 LS 0.
Slack B = 5 − 3 = 2. The critical path is the tasks with slack 0: A-C-D-E.

Question 6easy

PERT estimate for o = 1, m = 3, p = 11 days?

Show answer
4 days

(1+4⋅3+11)/6=24/6=4(1 + 4\cdot 3 + 11)/6 = 24/6 = 4 days.

Question 7easy

Classify: 'Members' payment card data must never be stored on the gym's servers.'

  1. Functional
  2. Operational
  3. Performance
  4. Security
Show answer
D) Security

A constraint about where data is stored and who can access it: security. It does not define a function but the security condition of a function.

Question 8easy

Which technique is most likely affected by the Hawthorne effect?

  1. Questionnaire
  2. Document analysis
  3. Observation
  4. JAD
Show answer
C) Observation

A person who knows they are being watched changes their behavior. This directly affects observation.

Question 9medium

'Checkout' always calls 'Calculate Total'; 'Apply Coupon' happens only if the customer enters a coupon code. Name both relationships to 'Checkout'.

Show answer
Calculate Total: <<include>> (Checkout → Calculate Total); Apply Coupon: <<extend>> (Apply Coupon → Checkout)

A shared part that runs every time is include, and the arrow leaves the base (Checkout). A conditional additional behavior is extend, and the arrow goes from the extending one (Apply Coupon) to the base.

Question 10medium

A House has Rooms; if the house is demolished, its rooms no longer exist. A Room belongs to exactly one House, a House has at least one Room. Give the relationship and multiplicities.

Show answer
Composition (filled diamond at House); House end 1, Room end 1..*

The part disappears with the whole and belongs to a single whole: composition. How many Houses does a Room have? 1 → at the House end. How many Rooms does a House have? 1..* → at the Room end.

Question 11easy

In a use case description, where do you write 'If the card is declined, the system asks for another card and returns to step 5'?

  1. Normal flow
  2. Preconditions
  3. Alternate/exceptional flows
  4. Brief description
Show answer
C) Alternate/exceptional flows

The normal flow is the single success path. The declined case is a deviation, and it is written in the alternate/exceptional flow with the step number of the deviation (e.g. 6a), and the return point is stated too.

Question 12medium

A university project has clear, stable, legally fixed requirements and auditors require full documentation. Which methodology is the safest choice?

  1. Scrum
  2. System prototyping
  3. Waterfall (or V-model)
  4. Throwaway prototyping
Show answer
C) Waterfall (or V-model)

If the requirements are clear and fixed and documentation is mandatory, structured methods (waterfall, V-model) fit. Agile and prototyping are strong when requirements are unclear.

Verification: The numeric answers (NPV, PVs, payback, ROI, TUFP/AFP, critical path, slack, PERT) were computed with node (verify/SEN2022/09.mjs, shared functions in lib.mjs). Conceptual questions were compared with the standard definitions on the week 1-8 pages.

Review card

SDLC: Planning → Analysis → Design → Implementation Deliverables: system request → proposal → specification → system Feasibility: technical (can we) / economic (worth it) / organizational (will it be used) PV = F/(1+r)^t; NPV = ΣPV - investment; ROI = (benefit - cost)/cost Payback = last negative year + shortfall / next year's flow FP: TUFP → APC = 0.65 + 0.01·PC → AFP → LOC → effort 1.4·KLOC → schedule 3·effort^(1/3) CPM: forward max, backward min, slack = LS - ES, critical = slack 0 PERT: (o + 4m + p)/6 Nonfunctional: operational, performance, security, cultural & political Use case: include mandatory (base→included), extend conditional (extending→base) Description: trigger, pre, normal flow, subflow, alternate, post Class: multiplicity from the opposite end; hollow diamond aggregation, filled composition Generalization: hollow triangle at the superclass