å°Šę•¬ēš„ å¾®äæ”걇ēŽ‡ļ¼š1円 ā‰ˆ 0.046166 元 ę”Æä»˜å®ę±‡ēŽ‡ļ¼š1円 ā‰ˆ 0.046257元 [退å‡ŗē™»å½•]
SlideShare a Scribd company logo
________________________________ _________________________________ _________________________________
NAME ID SIGNATURE
Department of Electrical and Computer Engineering, McGill University
ECSE 321 - Introduction to Software Engineering
Midterm Examination
October 30, 2003, 11:35am-12:50pm
Prof. Radu Negulescu
INSTRUCTIONS
ā€¢ Do NOT open this booklet until the start and end times of the examination are written on the board
ā€¢ Write your name, McGill student ID number, and signature on the cover of the answer booklet and at the
top of this page. Both booklets need to be handed in to the proctor at the end of the examination
ā€¢ This examination is closed book, closed notes. No aids permitted
ā€¢ Circle one answer only for each multiple-choice question in this examination booklet. Multiple-choice
questions are equally weighted. Each question has only one correct answer, which gets 2 marks. Wrong
answers get 0 marks or 1 mark (partial credit). No answers or multiple answers in a question get 0 marks
for that question
ā€¢ Write your answers to the essay-type questions in the separate answer booklet provided. Draw a diagonal
line over each scratch sheet in the answer booklet; scratch sheets will not be marked
ā€¢ This examination has 75 minutes only
Good luck!
Page 2
SECTION I ā€“ MULTIPLE-CHOICE QUESTIONS
CIRCLE ONE ANSWER ONLY IN EACH QUESTION
Question 1. Which of the following coding conventions, principles or guidelines will NOT help in the
development or maintenance of Java code?
(a) Lines of code that are logically related should be placed near one another (principle of proximity)
(b) Each method of a class should have comments that clearly explain the relationships to every other method
of that class (one comment for every pair of methods in the class)
(c) Code layout should highlight the logical structure of the code (fundamental principle of code layout)
(d) Four spaces should be used as the unit of indentation (Java coding convention)
(e) Names should be problem-oriented
Answer: (b). Commenting pairs of methods is clearly excessive and it would create massive redundancies by
restating the preconditions of one method in all the callers. The other guidelines are used standard practice.
Question 2. Waived. (All examinees receive 2 marks.)
Question 3. Which of the following statements is true for flat statechart representations of typical software
systems? (By ā€œflat statechartā€ we mean a statechart that does not use nesting or concurrency.)
(a) The number of states grows exponentially with the number of components in the system
(b) Each state explodes into several outgoing transitions
(c) A single transition might lead to several different states
(d) Large flat statecharts need to have more than one initial state
(e) None of the above
Answer: (a). It reflects an important phenomenon that limits what can be practically specified, by ā€œflatā€ state
machines or other means. You have experienced some mild state explosion in Assignment 2 Question 1 (b).
Question 4. Which of the following requirements is most likely to occur in a properly stated SRS? (Assume the
SRS is ā€œcompleteā€, i.e., none of the requirements below needs to be ā€œcompleteā€ all by itself.)
(a) ā€œThe system shall have a professional-looking user interface.ā€
(b) ā€œEach button in the Formatting toolbar shall have a tooltip.ā€
(c) ā€œThe average time for refreshing the display shall be 4 seconds or less.ā€
(d) ā€œThe maximum time for registering a key press into memory shall be 0.1 seconds or less.ā€
(e) ā€œThe minimum time for refreshing the display shall be 0 seconds, if possible.ā€
Answer: (b). It meets all the criteria of good requirements, and it is particularly good because it specifies a UI
feature (ā€œtooltipsā€) decoupled from the functionality features in the ā€œFormatting toolbarā€ (regardless of the
number of buttons). Option (c) looks good but it is somewhat ambiguous, since it might be interpreted as a
ā€œraster refresh rateā€ assumption rather than the ā€œrepainting graphical elementsā€ obligation. It is important to
avoid multiple ā€œstandardā€ interpretations even if some of them donā€™t make much sense from a technical
viewpoint.
Question 5. Waived. (All examinees receive 2 marks.)
Page 3
Source
register (Listener)
unregister (Listener)
cast (Event)
Listener
handle (Event)
*1
ConcreteListener
listenerState
handle (Event)
ConcreteSource
subjectState
cast (Event)
* 1
OLVWHQHU6WDWH HYHQWJHW6WDWH
Event
copyState
getState ()
*1
FUHDWH QHZ (YHQW H
IRU HDFK UHJLVWHUHG /LVWHQHU O
OKDQGOHH
event
(YHQW VRXUFH (YHQW OLVWHQHUV
Question 6. Consider the class diagram above, representing a basic event broadcast mechanism. Which of the
following statements is NOT true for this diagram?
(a) ConcreteSource objects can create new Event objects
(b) Listener objects can be added and removed at run time from a list maintained by a Source object
(c) The cast(Event) method of a ConcreteSource object calls the handle(Event) method of each registered
Listener object
(d) ConcreteListener objects update the copyState fields of the Event objects
(e) Each Listener object can be registered with only one Source object
Answer: (d), because in this diagram event objects cannot be updated. Although in some frameworks we could
have listeners registered with multiple sources, Option (e) is not quite right in this diagram because the Source-
Listener association has multiplicity 1-*. This diagram is consistent with the basic (unsophisticated)
implementations of event passing mechanisms.
Question 7. Consider the software driver for a web camera, which captures the video image in real time and
makes it available over the Internet. Which of the following can NOT be an actor for the software driver?
(a) The Internet connection of the local computer
(b) The port used by the video camera
(c) The user
(d) Arnold Schwarzenegger
(e) All of the above are good actors for the web camera software driver
(Hint: do not confuse good actors with actor instances.)
Answer: (d). Arnie is not an actor because the software doesnā€™t need to be ā€œawareā€ of him! Even if Arnie were to
purchase the software and use it as a user, Arnie can be at most an actor instance, but not an actor.
Page 4
Question 8. The guideline of 7 +/ā€“ 2 submodules per level is considered optimal for the following reason:
(a) It reduces the memory requirements of the program
(b) It matches approximately the number of distinct concepts that can be handled simultaneously by an
average developer
(c) It increases the speed of the program
(d) It appeals to the subjective taste of the average developers
(e) None of the above
Answer: (b). Psychological/cognitive considerations are the basis for many guidelines for improving productivity
in software engineering. This particular guideline has nothing to do with program performance or memory
requirements, and there is nothing subjective about it.
Controller
Model
subscriber
notifier
initiator
*
repository1
1
*
View
Question 9. Which of the following can be a sequence of events involved in the MVC architecture, according to
the class diagram above:
(a) A Model object sends an event to a View object, which notifies a Controller object
(b) A View object sends an event to a Model object, which notifies a Controller object
(c) A Controller object sends an event to a Model object, which notifies several View objects
(d) All of the above
(e) None of the above
Answer: (c). This is the only one consistent with the associations in the diagram and the basic MVC architecture.
In some variations of MVC, controllers might ā€œtalk toā€ views, but, even there, views do not ā€œtalk backā€ to
controllers.
The following two questions refer to the following insertion sort routine. (Array indices start at 1.)
routine insertionSort (A)
for j = 2 to length of array A
// INV: ...
key = A[j]
i = j ā€“ 1
while i  0 and A[i]  key do
A[i + 1] = A[i]
i = i ā€“ 1
end while
A[i + 1] = key
end for
Page 5
Question 10. Assume the insertionSort routine is used internally by a program. Which of the following
pre- and post-condition pairs is the most appropriate for insertionSort from a maintainability viewpoint?
(a) Pre: none; post: array is sorted
(b) Pre: array is not sorted; post: array is sorted
(c) Pre: array has at least one element; post: array is sorted
(d) Pre: array has at least two elements; post: array is sorted
(e) Pre: array reference is non-null; post: array is sorted
Answer: (e). As per tutorial, array references can (and should) be constrained by assertions. Option (a) is a close
call but Option (e) is more appropriate.
Question 11. Which of the following assertions is valid each time the program reaches the line ā€œINVā€?
(a) Items 1 through j are sorted
(b) Items 1 through j ā€“ 1 are sorted
(c) key equals A[j]
(d) i equals 0
(e) j equals 1
Answer: (b). All other options can be invalidated at some iteration of the loop.
Question 12. Keeping CRC cards to the size of 4x6 inches is considered important because:
(a) Software engineers prefer even numbers and inch measurement units
(b) This size allows just enough space to describe a class of optimal complexity in large script
(c) This size is conducive to optimal performance in implementing an object-oriented program
(d) All of the above
(e) None of the reasons above
Answer: (b). For this reason, some software developers actually feel very strongly about 4ā€X6ā€ CRC cards.
Options (a) and (c) are ludicrous.
Question 13. Which of the following applies to the statement ā€œIf class X uses defensive programming in each
method, then good programming practice recommends that any subclass Y that inherits from X should also use
defensive programming in each methodā€
(a) Always true
(b) Always false
(c) It depends on whether or not the subclass is used at the boundary of the system
(d) It depends on whether the class invariant of Y is stronger than that of X or the same
(e) None of the above
Answer: (d). Option (a) is close but not quite right. If class X uses defensive programming in method M then
method M accepts any values for the parameters and the class fields. The Liskov Substitution Principle (LSP)
requires that class Y has method M that can also take any values for the parameters. However, the invariant of
class Y could be stronger, in which case method M can make certain assumptions regarding the values of the
Page 6
class fields, without violating the LSP as long as proper encapsulation avoids direct access to the objectā€™s fields.
The LSP is an excellent rule of thumb for using inheritance.
Question 14. You are developing a command-line user interface. Which of the following design patterns is the
most likely to make it easy to add new commands in later versions of the program?
(a) Command
(b) Composite
(c) Observer
(d) Strategy
(e) Proxy
Answer: (a). The Command pattern is used specifically for the purpose of making it easy to add new commands.
Question 15. Which of the following checks is LEAST likely to detect maintainability problems in an object-
oriented design?
(a) Tracing in the class diagram one scenario for each use case
(b) Tracing each design element to a functional requirement
(c) Checking that none of the design elements can be removed
(d) Checking for naming conflicts
(e) Using calibrated stubs to predict performance
Answer: (e). Calibrated stubs will detect performance problems but not maintainability problems. Tracing
scenarios in the class diagrams and checking for naming conflicts will detect inconsistencies; tracing design
elements and checking for removable design elements will detect redundancies. Inconsistency and redundancy
lead to poor maintainability.
Page 7
SECTION II ā€“ ESSAY-TYPE QUESTIONS
WRITE YOUR ANSWERS IN THE ANSWER BOOKLET
Question 16. (Requirements, analysis)
You are developing ThumbsUp, a browser for the newest WebBerry, a popular wireless device that has a color
display and a mouse wheel, but no keyboard and no mouse. ThumbsUp has the following buttons only: ā€œBackā€,
ā€œForwardā€, ā€œPageā€, and ā€œExitā€, in this sequence. Initially, ThumbsUp is in the ā€œbuttonsā€ mode of operation, where
moving the wheel cycles through the buttons in the sequence above, and clicking the wheel activates the selected
button. As usual, buttons ā€œBackā€ and ā€œForwardā€ move back and forward through a list of recently visited web
pages, and button ā€œExitā€ exits the browser. Button ā€œPageā€ makes the browser go into the ā€œpageā€ mode of
operation where moving the wheel cycles through the hyperlinks on the currently displayed web page and double-
clicking the wheel activates the selected hyperlink and loads and displays a new web page. Triple-clicking the
wheel goes back to the ā€œbuttonsā€ mode. The default selections on entry to the ā€œbuttonsā€ and ā€œpageā€ modes are the
ā€œBackā€ button and the first hyperlink of the current page, respectively. The screen scrolls automatically in the
ā€œpageā€ mode to keep the current link within the viewable area. Each time ThumbsUp starts, it displays the home
page of WebBerryWorld.com, which has hyperlinks to several major web directories.
(a) Draw a use case diagram for ThumbsUp. Be sure to cover both stated and implied requirements and give
self-explaining names to the diagram elements. [10]
User
HttpServer
PageRestore
Back
LoadPage
Forward
LoadStartPage
Exit
ButtonsMode
include
include
PageMode
include
include
(b) Draw a sequence diagram for a scenario to visit 3 web pages (including the home page), then go back 1
web page, then go forward 1 web page to the last page visited. [10]

More Related Content

What's hot

Chapter 5 software design
Chapter 5 software designChapter 5 software design
Chapter 5 software design
Piyush Gogia
Ā 
Lecture 12 requirements modeling - (system analysis)
Lecture 12   requirements modeling - (system analysis)Lecture 12   requirements modeling - (system analysis)
Lecture 12 requirements modeling - (system analysis)
IIUI
Ā 
Software process and project metrics
Software process and project metricsSoftware process and project metrics
Software process and project metrics
Indu Sharma Bhardwaj
Ā 
Gathering requirements
Gathering requirementsGathering requirements
Gathering requirements
Doan Truong Giang
Ā 
Object diagram
Object diagramObject diagram
Object diagram
Preeti Mishra
Ā 
Design Concepts in Software Engineering-1.pptx
Design Concepts in Software Engineering-1.pptxDesign Concepts in Software Engineering-1.pptx
Design Concepts in Software Engineering-1.pptx
KarthigaiSelviS3
Ā 
Spiral model
Spiral modelSpiral model
Spiral model
Noraphyusin
Ā 
Requirement analysis with use case
Requirement analysis with use caseRequirement analysis with use case
Requirement analysis with use case
Rapeepan Thawornwanchai
Ā 
Lecture-1: Introduction to web engineering - course overview and grading scheme
Lecture-1: Introduction to web engineering - course overview and grading schemeLecture-1: Introduction to web engineering - course overview and grading scheme
Lecture-1: Introduction to web engineering - course overview and grading scheme
Mubashir Ali
Ā 
Software Engineering (Project Planning & Estimation)
Software Engineering (Project Planning &  Estimation)Software Engineering (Project Planning &  Estimation)
Software Engineering (Project Planning & Estimation)
ShudipPal
Ā 
Quality assurance and management, software engineering
Quality assurance and management, software engineeringQuality assurance and management, software engineering
Quality assurance and management, software engineering
Rupesh Vaishnav
Ā 
Software Engineering - chp4- design patterns
Software Engineering - chp4- design patternsSoftware Engineering - chp4- design patterns
Software Engineering - chp4- design patterns
Lilia Sfaxi
Ā 
PROTOTYPE MODEL
PROTOTYPE MODELPROTOTYPE MODEL
PROTOTYPE MODEL
shenagarg44
Ā 
Formal Approaches to SQA.pptx
Formal Approaches to SQA.pptxFormal Approaches to SQA.pptx
Formal Approaches to SQA.pptx
KarthigaiSelviS3
Ā 
Sdlc
SdlcSdlc
Sdlc
meenakshi sv
Ā 
Sequence diagram
Sequence diagramSequence diagram
Sequence diagram
Rahul Pola
Ā 
Software Development Life Cycle (SDLC )
Software Development Life Cycle (SDLC )Software Development Life Cycle (SDLC )
Software Development Life Cycle (SDLC )
eshtiyak
Ā 
AngularJS Directives
AngularJS DirectivesAngularJS Directives
AngularJS Directives
Eyal Vardi
Ā 
SDLC
SDLCSDLC
SDLC
chkjha
Ā 
Prototyping model
Prototyping modelPrototyping model
Prototyping model
Shirley Jenifer Joseph
Ā 

What's hot (20)

Chapter 5 software design
Chapter 5 software designChapter 5 software design
Chapter 5 software design
Ā 
Lecture 12 requirements modeling - (system analysis)
Lecture 12   requirements modeling - (system analysis)Lecture 12   requirements modeling - (system analysis)
Lecture 12 requirements modeling - (system analysis)
Ā 
Software process and project metrics
Software process and project metricsSoftware process and project metrics
Software process and project metrics
Ā 
Gathering requirements
Gathering requirementsGathering requirements
Gathering requirements
Ā 
Object diagram
Object diagramObject diagram
Object diagram
Ā 
Design Concepts in Software Engineering-1.pptx
Design Concepts in Software Engineering-1.pptxDesign Concepts in Software Engineering-1.pptx
Design Concepts in Software Engineering-1.pptx
Ā 
Spiral model
Spiral modelSpiral model
Spiral model
Ā 
Requirement analysis with use case
Requirement analysis with use caseRequirement analysis with use case
Requirement analysis with use case
Ā 
Lecture-1: Introduction to web engineering - course overview and grading scheme
Lecture-1: Introduction to web engineering - course overview and grading schemeLecture-1: Introduction to web engineering - course overview and grading scheme
Lecture-1: Introduction to web engineering - course overview and grading scheme
Ā 
Software Engineering (Project Planning & Estimation)
Software Engineering (Project Planning &  Estimation)Software Engineering (Project Planning &  Estimation)
Software Engineering (Project Planning & Estimation)
Ā 
Quality assurance and management, software engineering
Quality assurance and management, software engineeringQuality assurance and management, software engineering
Quality assurance and management, software engineering
Ā 
Software Engineering - chp4- design patterns
Software Engineering - chp4- design patternsSoftware Engineering - chp4- design patterns
Software Engineering - chp4- design patterns
Ā 
PROTOTYPE MODEL
PROTOTYPE MODELPROTOTYPE MODEL
PROTOTYPE MODEL
Ā 
Formal Approaches to SQA.pptx
Formal Approaches to SQA.pptxFormal Approaches to SQA.pptx
Formal Approaches to SQA.pptx
Ā 
Sdlc
SdlcSdlc
Sdlc
Ā 
Sequence diagram
Sequence diagramSequence diagram
Sequence diagram
Ā 
Software Development Life Cycle (SDLC )
Software Development Life Cycle (SDLC )Software Development Life Cycle (SDLC )
Software Development Life Cycle (SDLC )
Ā 
AngularJS Directives
AngularJS DirectivesAngularJS Directives
AngularJS Directives
Ā 
SDLC
SDLCSDLC
SDLC
Ā 
Prototyping model
Prototyping modelPrototyping model
Prototyping model
Ā 

Viewers also liked

Science midterm exam (10)
Science midterm exam (10)Science midterm exam (10)
Science midterm exam (10)
ariyacca
Ā 
Gereksinimleri Meydana Ƈıkarma Teknikleri
Gereksinimleri Meydana Ƈıkarma Teknikleri Gereksinimleri Meydana Ƈıkarma Teknikleri
Gereksinimleri Meydana Ƈıkarma Teknikleri
Bilge Adam Kurumsal
Ā 
TALAT Lecture 3300: Fundamentals of Metal Forming
TALAT Lecture 3300: Fundamentals of Metal FormingTALAT Lecture 3300: Fundamentals of Metal Forming
TALAT Lecture 3300: Fundamentals of Metal Forming
CORE-Materials
Ā 
Kssr English Yr 4 Mid term exam
Kssr  English Yr 4 Mid term examKssr  English Yr 4 Mid term exam
Kssr English Yr 4 Mid term exam
Nazliana Nadziruddin
Ā 
I p-o in different data processing systems
I p-o in different data processing systemsI p-o in different data processing systems
I p-o in different data processing systems
Kinshook Chaturvedi
Ā 
Critical System Specification in Software Engineering SE17
Critical System Specification in Software Engineering SE17Critical System Specification in Software Engineering SE17
Critical System Specification in Software Engineering SE17
koolkampus
Ā 
Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)
Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)
Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)Ahmet Yanik
Ā 
Ian Sommerville, Software Engineering, 9th Edition Ch1
Ian Sommerville,  Software Engineering, 9th Edition Ch1Ian Sommerville,  Software Engineering, 9th Edition Ch1
Ian Sommerville, Software Engineering, 9th Edition Ch1
Mohammed Romi
Ā 
Mid term examination -2011 class vi
Mid term examination -2011 class viMid term examination -2011 class vi
Mid term examination -2011 class vi
Asad Shafat
Ā 
U4 p0 overview of metal forming
U4 p0 overview of metal formingU4 p0 overview of metal forming
U4 p0 overview of metal forming
gautam buddha university
Ā 
Topic 4 metal forming 160214
Topic 4 metal forming 160214Topic 4 metal forming 160214
Topic 4 metal forming 160214
Huai123
Ā 
Ian Sommerville, Software Engineering, 9th Edition Ch 4
Ian Sommerville,  Software Engineering, 9th Edition Ch 4Ian Sommerville,  Software Engineering, 9th Edition Ch 4
Ian Sommerville, Software Engineering, 9th Edition Ch 4
Mohammed Romi
Ā 
Ch2 sw processes
Ch2 sw processesCh2 sw processes
Ch2 sw processes
software-engineering-book
Ā 
Semiotics
SemioticsSemiotics
Semiotics
Melda Yildiz
Ā 
Metal forming processes
Metal forming processesMetal forming processes
Metal forming processes
Er Deepak Sharma
Ā 
Requirement elicitation
Requirement elicitationRequirement elicitation
Requirement elicitation
vivacemente
Ā 
Enterprise Systems: SCM, CRM, & ERP
Enterprise Systems: SCM, CRM, & ERPEnterprise Systems: SCM, CRM, & ERP
Enterprise Systems: SCM, CRM, & ERP
UMaine
Ā 

Viewers also liked (17)

Science midterm exam (10)
Science midterm exam (10)Science midterm exam (10)
Science midterm exam (10)
Ā 
Gereksinimleri Meydana Ƈıkarma Teknikleri
Gereksinimleri Meydana Ƈıkarma Teknikleri Gereksinimleri Meydana Ƈıkarma Teknikleri
Gereksinimleri Meydana Ƈıkarma Teknikleri
Ā 
TALAT Lecture 3300: Fundamentals of Metal Forming
TALAT Lecture 3300: Fundamentals of Metal FormingTALAT Lecture 3300: Fundamentals of Metal Forming
TALAT Lecture 3300: Fundamentals of Metal Forming
Ā 
Kssr English Yr 4 Mid term exam
Kssr  English Yr 4 Mid term examKssr  English Yr 4 Mid term exam
Kssr English Yr 4 Mid term exam
Ā 
I p-o in different data processing systems
I p-o in different data processing systemsI p-o in different data processing systems
I p-o in different data processing systems
Ā 
Critical System Specification in Software Engineering SE17
Critical System Specification in Software Engineering SE17Critical System Specification in Software Engineering SE17
Critical System Specification in Software Engineering SE17
Ā 
Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)
Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)
Yazilim miĢ‡mariĢ‡leriĢ‡(aoy)
Ā 
Ian Sommerville, Software Engineering, 9th Edition Ch1
Ian Sommerville,  Software Engineering, 9th Edition Ch1Ian Sommerville,  Software Engineering, 9th Edition Ch1
Ian Sommerville, Software Engineering, 9th Edition Ch1
Ā 
Mid term examination -2011 class vi
Mid term examination -2011 class viMid term examination -2011 class vi
Mid term examination -2011 class vi
Ā 
U4 p0 overview of metal forming
U4 p0 overview of metal formingU4 p0 overview of metal forming
U4 p0 overview of metal forming
Ā 
Topic 4 metal forming 160214
Topic 4 metal forming 160214Topic 4 metal forming 160214
Topic 4 metal forming 160214
Ā 
Ian Sommerville, Software Engineering, 9th Edition Ch 4
Ian Sommerville,  Software Engineering, 9th Edition Ch 4Ian Sommerville,  Software Engineering, 9th Edition Ch 4
Ian Sommerville, Software Engineering, 9th Edition Ch 4
Ā 
Ch2 sw processes
Ch2 sw processesCh2 sw processes
Ch2 sw processes
Ā 
Semiotics
SemioticsSemiotics
Semiotics
Ā 
Metal forming processes
Metal forming processesMetal forming processes
Metal forming processes
Ā 
Requirement elicitation
Requirement elicitationRequirement elicitation
Requirement elicitation
Ā 
Enterprise Systems: SCM, CRM, & ERP
Enterprise Systems: SCM, CRM, & ERPEnterprise Systems: SCM, CRM, & ERP
Enterprise Systems: SCM, CRM, & ERP
Ā 

Similar to Midterm Exam Solutions Fall03

Final Exam Solutions Fall02
Final Exam Solutions Fall02Final Exam Solutions Fall02
Final Exam Solutions Fall02
Radu_Negulescu
Ā 
BDS_QA.pdf
BDS_QA.pdfBDS_QA.pdf
BDS_QA.pdf
NikunjaParida1
Ā 
Name _______________________________ Class time __________.docx
Name _______________________________    Class time __________.docxName _______________________________    Class time __________.docx
Name _______________________________ Class time __________.docx
rosemarybdodson23141
Ā 
Higher Homework
Higher HomeworkHigher Homework
Higher Homework
mrsmackenzie
Ā 
midterm_fa07.pdf
midterm_fa07.pdfmidterm_fa07.pdf
midterm_fa07.pdf
RavinderKSingla
Ā 
Session 3 Software Engineering UGC NET.pdf
Session 3 Software Engineering UGC NET.pdfSession 3 Software Engineering UGC NET.pdf
Session 3 Software Engineering UGC NET.pdf
sangeethachandran
Ā 
Semester ii
Semester   iiSemester   ii
Semester ii
smumbahelp
Ā 
Primilimnary round questions with answers
Primilimnary round questions with answersPrimilimnary round questions with answers
Primilimnary round questions with answers
Dr. C.V. Suresh Babu
Ā 
Illogical engineers
Illogical engineersIllogical engineers
Illogical engineers
Pawel Szulc
Ā 
Illogical engineers
Illogical engineersIllogical engineers
Illogical engineers
Pawel Szulc
Ā 
Gate-Cs 1994
Gate-Cs 1994Gate-Cs 1994
Gate-Cs 1994
Ravi Rajput
Ā 
Specialist marketing officer professional knowledge questions.pdf(1)
Specialist marketing officer professional knowledge questions.pdf(1)Specialist marketing officer professional knowledge questions.pdf(1)
Specialist marketing officer professional knowledge questions.pdf(1)
Nivi Mohanty
Ā 
Software Architecture - Quiz Questions
Software Architecture - Quiz QuestionsSoftware Architecture - Quiz Questions
Software Architecture - Quiz Questions
Ganesh Samarthyam
Ā 
Software Architecture - Quiz Questions
Software Architecture - Quiz QuestionsSoftware Architecture - Quiz Questions
Software Architecture - Quiz Questions
CodeOps Technologies LLP
Ā 
Gate-Cs 1992
Gate-Cs 1992Gate-Cs 1992
Gate-Cs 1992
Ravi Rajput
Ā 
final_2014.pdf
final_2014.pdffinal_2014.pdf
final_2014.pdf
RavinderKSingla
Ā 
Subject name Object Oriented Analysis and DesignMultiple Choice (.pdf
Subject name Object Oriented Analysis and DesignMultiple Choice (.pdfSubject name Object Oriented Analysis and DesignMultiple Choice (.pdf
Subject name Object Oriented Analysis and DesignMultiple Choice (.pdf
akilastationarrymdu
Ā 
PGCET Computer science 2017 question paper
PGCET Computer science 2017 question paperPGCET Computer science 2017 question paper
PGCET Computer science 2017 question paper
Eneutron
Ā 
GSP 125 Entire Course NEW
GSP 125 Entire Course NEWGSP 125 Entire Course NEW
GSP 125 Entire Course NEW
shyamuopten
Ā 
CAPE Computer Science Unit 1 Paper 1 - Practice Paper
CAPE Computer Science Unit 1 Paper 1 - Practice PaperCAPE Computer Science Unit 1 Paper 1 - Practice Paper
CAPE Computer Science Unit 1 Paper 1 - Practice Paper
Alex Stewart
Ā 

Similar to Midterm Exam Solutions Fall03 (20)

Final Exam Solutions Fall02
Final Exam Solutions Fall02Final Exam Solutions Fall02
Final Exam Solutions Fall02
Ā 
BDS_QA.pdf
BDS_QA.pdfBDS_QA.pdf
BDS_QA.pdf
Ā 
Name _______________________________ Class time __________.docx
Name _______________________________    Class time __________.docxName _______________________________    Class time __________.docx
Name _______________________________ Class time __________.docx
Ā 
Higher Homework
Higher HomeworkHigher Homework
Higher Homework
Ā 
midterm_fa07.pdf
midterm_fa07.pdfmidterm_fa07.pdf
midterm_fa07.pdf
Ā 
Session 3 Software Engineering UGC NET.pdf
Session 3 Software Engineering UGC NET.pdfSession 3 Software Engineering UGC NET.pdf
Session 3 Software Engineering UGC NET.pdf
Ā 
Semester ii
Semester   iiSemester   ii
Semester ii
Ā 
Primilimnary round questions with answers
Primilimnary round questions with answersPrimilimnary round questions with answers
Primilimnary round questions with answers
Ā 
Illogical engineers
Illogical engineersIllogical engineers
Illogical engineers
Ā 
Illogical engineers
Illogical engineersIllogical engineers
Illogical engineers
Ā 
Gate-Cs 1994
Gate-Cs 1994Gate-Cs 1994
Gate-Cs 1994
Ā 
Specialist marketing officer professional knowledge questions.pdf(1)
Specialist marketing officer professional knowledge questions.pdf(1)Specialist marketing officer professional knowledge questions.pdf(1)
Specialist marketing officer professional knowledge questions.pdf(1)
Ā 
Software Architecture - Quiz Questions
Software Architecture - Quiz QuestionsSoftware Architecture - Quiz Questions
Software Architecture - Quiz Questions
Ā 
Software Architecture - Quiz Questions
Software Architecture - Quiz QuestionsSoftware Architecture - Quiz Questions
Software Architecture - Quiz Questions
Ā 
Gate-Cs 1992
Gate-Cs 1992Gate-Cs 1992
Gate-Cs 1992
Ā 
final_2014.pdf
final_2014.pdffinal_2014.pdf
final_2014.pdf
Ā 
Subject name Object Oriented Analysis and DesignMultiple Choice (.pdf
Subject name Object Oriented Analysis and DesignMultiple Choice (.pdfSubject name Object Oriented Analysis and DesignMultiple Choice (.pdf
Subject name Object Oriented Analysis and DesignMultiple Choice (.pdf
Ā 
PGCET Computer science 2017 question paper
PGCET Computer science 2017 question paperPGCET Computer science 2017 question paper
PGCET Computer science 2017 question paper
Ā 
GSP 125 Entire Course NEW
GSP 125 Entire Course NEWGSP 125 Entire Course NEW
GSP 125 Entire Course NEW
Ā 
CAPE Computer Science Unit 1 Paper 1 - Practice Paper
CAPE Computer Science Unit 1 Paper 1 - Practice PaperCAPE Computer Science Unit 1 Paper 1 - Practice Paper
CAPE Computer Science Unit 1 Paper 1 - Practice Paper
Ā 

More from Radu_Negulescu

Intro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality AssuranceIntro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality Assurance
Radu_Negulescu
Ā 
Midterm Exam Solutions Fall02
Midterm Exam Solutions Fall02Midterm Exam Solutions Fall02
Midterm Exam Solutions Fall02
Radu_Negulescu
Ā 
Intro to Software Engineering - Life Cycle Models
Intro to Software Engineering - Life Cycle ModelsIntro to Software Engineering - Life Cycle Models
Intro to Software Engineering - Life Cycle Models
Radu_Negulescu
Ā 
Intro to Software Engineering - Software Testing
Intro to Software Engineering - Software TestingIntro to Software Engineering - Software Testing
Intro to Software Engineering - Software Testing
Radu_Negulescu
Ā 
Intro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality AssuranceIntro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality Assurance
Radu_Negulescu
Ā 
Intro to Software Engineering - Software Design
Intro to Software Engineering - Software DesignIntro to Software Engineering - Software Design
Intro to Software Engineering - Software Design
Radu_Negulescu
Ā 
Intro to Software Engineering - Module Design
Intro to Software Engineering - Module DesignIntro to Software Engineering - Module Design
Intro to Software Engineering - Module Design
Radu_Negulescu
Ā 
Intro to Software Engineering - Requirements Analysis
Intro to Software Engineering - Requirements AnalysisIntro to Software Engineering - Requirements Analysis
Intro to Software Engineering - Requirements Analysis
Radu_Negulescu
Ā 
Intro to Software Engineering - Coding Standards
Intro to Software Engineering - Coding StandardsIntro to Software Engineering - Coding Standards
Intro to Software Engineering - Coding Standards
Radu_Negulescu
Ā 
Software Engineering Practice - Software Quality Management
Software Engineering Practice - Software Quality ManagementSoftware Engineering Practice - Software Quality Management
Software Engineering Practice - Software Quality Management
Radu_Negulescu
Ā 
Software Engineering Practice - Software Metrics and Estimation
Software Engineering Practice - Software Metrics and EstimationSoftware Engineering Practice - Software Metrics and Estimation
Software Engineering Practice - Software Metrics and Estimation
Radu_Negulescu
Ā 
Software Engineering Practice - Software Business Basics
Software Engineering Practice - Software Business BasicsSoftware Engineering Practice - Software Business Basics
Software Engineering Practice - Software Business Basics
Radu_Negulescu
Ā 
Software Engineering Practice - Project management
Software Engineering Practice - Project managementSoftware Engineering Practice - Project management
Software Engineering Practice - Project management
Radu_Negulescu
Ā 
Software Engineering Practice - Configuration management
Software Engineering Practice - Configuration managementSoftware Engineering Practice - Configuration management
Software Engineering Practice - Configuration management
Radu_Negulescu
Ā 
Software Engineering Practice - Advanced Development Methodologies
Software Engineering Practice - Advanced Development MethodologiesSoftware Engineering Practice - Advanced Development Methodologies
Software Engineering Practice - Advanced Development Methodologies
Radu_Negulescu
Ā 

More from Radu_Negulescu (15)

Intro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality AssuranceIntro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality Assurance
Ā 
Midterm Exam Solutions Fall02
Midterm Exam Solutions Fall02Midterm Exam Solutions Fall02
Midterm Exam Solutions Fall02
Ā 
Intro to Software Engineering - Life Cycle Models
Intro to Software Engineering - Life Cycle ModelsIntro to Software Engineering - Life Cycle Models
Intro to Software Engineering - Life Cycle Models
Ā 
Intro to Software Engineering - Software Testing
Intro to Software Engineering - Software TestingIntro to Software Engineering - Software Testing
Intro to Software Engineering - Software Testing
Ā 
Intro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality AssuranceIntro to Software Engineering - Software Quality Assurance
Intro to Software Engineering - Software Quality Assurance
Ā 
Intro to Software Engineering - Software Design
Intro to Software Engineering - Software DesignIntro to Software Engineering - Software Design
Intro to Software Engineering - Software Design
Ā 
Intro to Software Engineering - Module Design
Intro to Software Engineering - Module DesignIntro to Software Engineering - Module Design
Intro to Software Engineering - Module Design
Ā 
Intro to Software Engineering - Requirements Analysis
Intro to Software Engineering - Requirements AnalysisIntro to Software Engineering - Requirements Analysis
Intro to Software Engineering - Requirements Analysis
Ā 
Intro to Software Engineering - Coding Standards
Intro to Software Engineering - Coding StandardsIntro to Software Engineering - Coding Standards
Intro to Software Engineering - Coding Standards
Ā 
Software Engineering Practice - Software Quality Management
Software Engineering Practice - Software Quality ManagementSoftware Engineering Practice - Software Quality Management
Software Engineering Practice - Software Quality Management
Ā 
Software Engineering Practice - Software Metrics and Estimation
Software Engineering Practice - Software Metrics and EstimationSoftware Engineering Practice - Software Metrics and Estimation
Software Engineering Practice - Software Metrics and Estimation
Ā 
Software Engineering Practice - Software Business Basics
Software Engineering Practice - Software Business BasicsSoftware Engineering Practice - Software Business Basics
Software Engineering Practice - Software Business Basics
Ā 
Software Engineering Practice - Project management
Software Engineering Practice - Project managementSoftware Engineering Practice - Project management
Software Engineering Practice - Project management
Ā 
Software Engineering Practice - Configuration management
Software Engineering Practice - Configuration managementSoftware Engineering Practice - Configuration management
Software Engineering Practice - Configuration management
Ā 
Software Engineering Practice - Advanced Development Methodologies
Software Engineering Practice - Advanced Development MethodologiesSoftware Engineering Practice - Advanced Development Methodologies
Software Engineering Practice - Advanced Development Methodologies
Ā 

Recently uploaded

QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...
QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...
QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...
AlexanderRichford
Ā 
Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...
Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...
Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...
anilsa9823
Ā 
An All-Around Benchmark of the DBaaS Market
An All-Around Benchmark of the DBaaS MarketAn All-Around Benchmark of the DBaaS Market
An All-Around Benchmark of the DBaaS Market
ScyllaDB
Ā 
ScyllaDB Tablets: Rethinking Replication
ScyllaDB Tablets: Rethinking ReplicationScyllaDB Tablets: Rethinking Replication
ScyllaDB Tablets: Rethinking Replication
ScyllaDB
Ā 
Elasticity vs. State? Exploring Kafka Streams Cassandra State Store
Elasticity vs. State? Exploring Kafka Streams Cassandra State StoreElasticity vs. State? Exploring Kafka Streams Cassandra State Store
Elasticity vs. State? Exploring Kafka Streams Cassandra State Store
ScyllaDB
Ā 
Northern Engraving | Modern Metal Trim, Nameplates and Appliance Panels
Northern Engraving | Modern Metal Trim, Nameplates and Appliance PanelsNorthern Engraving | Modern Metal Trim, Nameplates and Appliance Panels
Northern Engraving | Modern Metal Trim, Nameplates and Appliance Panels
Northern Engraving
Ā 
Facilitation Skills - When to Use and Why.pptx
Facilitation Skills - When to Use and Why.pptxFacilitation Skills - When to Use and Why.pptx
Facilitation Skills - When to Use and Why.pptx
Knoldus Inc.
Ā 
An Introduction to All Data Enterprise Integration
An Introduction to All Data Enterprise IntegrationAn Introduction to All Data Enterprise Integration
An Introduction to All Data Enterprise Integration
Safe Software
Ā 
Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...
Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...
Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...
dipikamodels1
Ā 
Introduction to ThousandEyes AMER Webinar
Introduction  to ThousandEyes AMER WebinarIntroduction  to ThousandEyes AMER Webinar
Introduction to ThousandEyes AMER Webinar
ThousandEyes
Ā 
Automation Student Developers Session 3: Introduction to UI Automation
Automation Student Developers Session 3: Introduction to UI AutomationAutomation Student Developers Session 3: Introduction to UI Automation
Automation Student Developers Session 3: Introduction to UI Automation
UiPathCommunity
Ā 
Chapter 5 - Managing Test Activities V4.0
Chapter 5 - Managing Test Activities V4.0Chapter 5 - Managing Test Activities V4.0
Chapter 5 - Managing Test Activities V4.0
Neeraj Kumar Singh
Ā 
Lee Barnes - Path to Becoming an Effective Test Automation Engineer.pdf
Lee Barnes - Path to Becoming an Effective Test Automation Engineer.pdfLee Barnes - Path to Becoming an Effective Test Automation Engineer.pdf
Lee Barnes - Path to Becoming an Effective Test Automation Engineer.pdf
leebarnesutopia
Ā 
Communications Mining Series - Zero to Hero - Session 2
Communications Mining Series - Zero to Hero - Session 2Communications Mining Series - Zero to Hero - Session 2
Communications Mining Series - Zero to Hero - Session 2
DianaGray10
Ā 
Building a Semantic Layer of your Data Platform
Building a Semantic Layer of your Data PlatformBuilding a Semantic Layer of your Data Platform
Building a Semantic Layer of your Data Platform
Enterprise Knowledge
Ā 
Demystifying Knowledge Management through Storytelling
Demystifying Knowledge Management through StorytellingDemystifying Knowledge Management through Storytelling
Demystifying Knowledge Management through Storytelling
Enterprise Knowledge
Ā 
Guidelines for Effective Data Visualization
Guidelines for Effective Data VisualizationGuidelines for Effective Data Visualization
Guidelines for Effective Data Visualization
UmmeSalmaM1
Ā 
APJC Introduction to ThousandEyes Webinar
APJC Introduction to ThousandEyes WebinarAPJC Introduction to ThousandEyes Webinar
APJC Introduction to ThousandEyes Webinar
ThousandEyes
Ā 
Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...
Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...
Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...
manji sharman06
Ā 
QA or the Highway - Component Testing: Bridging the gap between frontend appl...
QA or the Highway - Component Testing: Bridging the gap between frontend appl...QA or the Highway - Component Testing: Bridging the gap between frontend appl...
QA or the Highway - Component Testing: Bridging the gap between frontend appl...
zjhamm304
Ā 

Recently uploaded (20)

QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...
QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...
QR Secure: A Hybrid Approach Using Machine Learning and Security Validation F...
Ā 
Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...
Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...
Call Girls Chennai ā˜Žļø +91-7426014248 šŸ˜ Chennai Call Girl Beauty Girls Chennai...
Ā 
An All-Around Benchmark of the DBaaS Market
An All-Around Benchmark of the DBaaS MarketAn All-Around Benchmark of the DBaaS Market
An All-Around Benchmark of the DBaaS Market
Ā 
ScyllaDB Tablets: Rethinking Replication
ScyllaDB Tablets: Rethinking ReplicationScyllaDB Tablets: Rethinking Replication
ScyllaDB Tablets: Rethinking Replication
Ā 
Elasticity vs. State? Exploring Kafka Streams Cassandra State Store
Elasticity vs. State? Exploring Kafka Streams Cassandra State StoreElasticity vs. State? Exploring Kafka Streams Cassandra State Store
Elasticity vs. State? Exploring Kafka Streams Cassandra State Store
Ā 
Northern Engraving | Modern Metal Trim, Nameplates and Appliance Panels
Northern Engraving | Modern Metal Trim, Nameplates and Appliance PanelsNorthern Engraving | Modern Metal Trim, Nameplates and Appliance Panels
Northern Engraving | Modern Metal Trim, Nameplates and Appliance Panels
Ā 
Facilitation Skills - When to Use and Why.pptx
Facilitation Skills - When to Use and Why.pptxFacilitation Skills - When to Use and Why.pptx
Facilitation Skills - When to Use and Why.pptx
Ā 
An Introduction to All Data Enterprise Integration
An Introduction to All Data Enterprise IntegrationAn Introduction to All Data Enterprise Integration
An Introduction to All Data Enterprise Integration
Ā 
Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...
Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...
Call Girls Kochi šŸ’ÆCall Us šŸ” 7426014248 šŸ” Independent Kochi Escorts Service Av...
Ā 
Introduction to ThousandEyes AMER Webinar
Introduction  to ThousandEyes AMER WebinarIntroduction  to ThousandEyes AMER Webinar
Introduction to ThousandEyes AMER Webinar
Ā 
Automation Student Developers Session 3: Introduction to UI Automation
Automation Student Developers Session 3: Introduction to UI AutomationAutomation Student Developers Session 3: Introduction to UI Automation
Automation Student Developers Session 3: Introduction to UI Automation
Ā 
Chapter 5 - Managing Test Activities V4.0
Chapter 5 - Managing Test Activities V4.0Chapter 5 - Managing Test Activities V4.0
Chapter 5 - Managing Test Activities V4.0
Ā 
Lee Barnes - Path to Becoming an Effective Test Automation Engineer.pdf
Lee Barnes - Path to Becoming an Effective Test Automation Engineer.pdfLee Barnes - Path to Becoming an Effective Test Automation Engineer.pdf
Lee Barnes - Path to Becoming an Effective Test Automation Engineer.pdf
Ā 
Communications Mining Series - Zero to Hero - Session 2
Communications Mining Series - Zero to Hero - Session 2Communications Mining Series - Zero to Hero - Session 2
Communications Mining Series - Zero to Hero - Session 2
Ā 
Building a Semantic Layer of your Data Platform
Building a Semantic Layer of your Data PlatformBuilding a Semantic Layer of your Data Platform
Building a Semantic Layer of your Data Platform
Ā 
Demystifying Knowledge Management through Storytelling
Demystifying Knowledge Management through StorytellingDemystifying Knowledge Management through Storytelling
Demystifying Knowledge Management through Storytelling
Ā 
Guidelines for Effective Data Visualization
Guidelines for Effective Data VisualizationGuidelines for Effective Data Visualization
Guidelines for Effective Data Visualization
Ā 
APJC Introduction to ThousandEyes Webinar
APJC Introduction to ThousandEyes WebinarAPJC Introduction to ThousandEyes Webinar
APJC Introduction to ThousandEyes Webinar
Ā 
Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...
Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...
Call Girls ChandigarhšŸ”„7023059433šŸ”„Agency Profile Escorts in Chandigarh Availab...
Ā 
QA or the Highway - Component Testing: Bridging the gap between frontend appl...
QA or the Highway - Component Testing: Bridging the gap between frontend appl...QA or the Highway - Component Testing: Bridging the gap between frontend appl...
QA or the Highway - Component Testing: Bridging the gap between frontend appl...
Ā 

Midterm Exam Solutions Fall03

  • 1. ________________________________ _________________________________ _________________________________ NAME ID SIGNATURE Department of Electrical and Computer Engineering, McGill University ECSE 321 - Introduction to Software Engineering Midterm Examination October 30, 2003, 11:35am-12:50pm Prof. Radu Negulescu INSTRUCTIONS ā€¢ Do NOT open this booklet until the start and end times of the examination are written on the board ā€¢ Write your name, McGill student ID number, and signature on the cover of the answer booklet and at the top of this page. Both booklets need to be handed in to the proctor at the end of the examination ā€¢ This examination is closed book, closed notes. No aids permitted ā€¢ Circle one answer only for each multiple-choice question in this examination booklet. Multiple-choice questions are equally weighted. Each question has only one correct answer, which gets 2 marks. Wrong answers get 0 marks or 1 mark (partial credit). No answers or multiple answers in a question get 0 marks for that question ā€¢ Write your answers to the essay-type questions in the separate answer booklet provided. Draw a diagonal line over each scratch sheet in the answer booklet; scratch sheets will not be marked ā€¢ This examination has 75 minutes only Good luck!
  • 2. Page 2 SECTION I ā€“ MULTIPLE-CHOICE QUESTIONS CIRCLE ONE ANSWER ONLY IN EACH QUESTION Question 1. Which of the following coding conventions, principles or guidelines will NOT help in the development or maintenance of Java code? (a) Lines of code that are logically related should be placed near one another (principle of proximity) (b) Each method of a class should have comments that clearly explain the relationships to every other method of that class (one comment for every pair of methods in the class) (c) Code layout should highlight the logical structure of the code (fundamental principle of code layout) (d) Four spaces should be used as the unit of indentation (Java coding convention) (e) Names should be problem-oriented Answer: (b). Commenting pairs of methods is clearly excessive and it would create massive redundancies by restating the preconditions of one method in all the callers. The other guidelines are used standard practice. Question 2. Waived. (All examinees receive 2 marks.) Question 3. Which of the following statements is true for flat statechart representations of typical software systems? (By ā€œflat statechartā€ we mean a statechart that does not use nesting or concurrency.) (a) The number of states grows exponentially with the number of components in the system (b) Each state explodes into several outgoing transitions (c) A single transition might lead to several different states (d) Large flat statecharts need to have more than one initial state (e) None of the above Answer: (a). It reflects an important phenomenon that limits what can be practically specified, by ā€œflatā€ state machines or other means. You have experienced some mild state explosion in Assignment 2 Question 1 (b). Question 4. Which of the following requirements is most likely to occur in a properly stated SRS? (Assume the SRS is ā€œcompleteā€, i.e., none of the requirements below needs to be ā€œcompleteā€ all by itself.) (a) ā€œThe system shall have a professional-looking user interface.ā€ (b) ā€œEach button in the Formatting toolbar shall have a tooltip.ā€ (c) ā€œThe average time for refreshing the display shall be 4 seconds or less.ā€ (d) ā€œThe maximum time for registering a key press into memory shall be 0.1 seconds or less.ā€ (e) ā€œThe minimum time for refreshing the display shall be 0 seconds, if possible.ā€ Answer: (b). It meets all the criteria of good requirements, and it is particularly good because it specifies a UI feature (ā€œtooltipsā€) decoupled from the functionality features in the ā€œFormatting toolbarā€ (regardless of the number of buttons). Option (c) looks good but it is somewhat ambiguous, since it might be interpreted as a ā€œraster refresh rateā€ assumption rather than the ā€œrepainting graphical elementsā€ obligation. It is important to avoid multiple ā€œstandardā€ interpretations even if some of them donā€™t make much sense from a technical viewpoint. Question 5. Waived. (All examinees receive 2 marks.)
  • 3. Page 3 Source register (Listener) unregister (Listener) cast (Event) Listener handle (Event) *1 ConcreteListener listenerState handle (Event) ConcreteSource subjectState cast (Event) * 1 OLVWHQHU6WDWH HYHQWJHW6WDWH
  • 4. Event copyState getState () *1 FUHDWH QHZ (YHQW H IRU HDFK UHJLVWHUHG /LVWHQHU O OKDQGOHH
  • 5. event (YHQW VRXUFH (YHQW OLVWHQHUV Question 6. Consider the class diagram above, representing a basic event broadcast mechanism. Which of the following statements is NOT true for this diagram? (a) ConcreteSource objects can create new Event objects (b) Listener objects can be added and removed at run time from a list maintained by a Source object (c) The cast(Event) method of a ConcreteSource object calls the handle(Event) method of each registered Listener object (d) ConcreteListener objects update the copyState fields of the Event objects (e) Each Listener object can be registered with only one Source object Answer: (d), because in this diagram event objects cannot be updated. Although in some frameworks we could have listeners registered with multiple sources, Option (e) is not quite right in this diagram because the Source- Listener association has multiplicity 1-*. This diagram is consistent with the basic (unsophisticated) implementations of event passing mechanisms. Question 7. Consider the software driver for a web camera, which captures the video image in real time and makes it available over the Internet. Which of the following can NOT be an actor for the software driver? (a) The Internet connection of the local computer (b) The port used by the video camera (c) The user (d) Arnold Schwarzenegger (e) All of the above are good actors for the web camera software driver (Hint: do not confuse good actors with actor instances.) Answer: (d). Arnie is not an actor because the software doesnā€™t need to be ā€œawareā€ of him! Even if Arnie were to purchase the software and use it as a user, Arnie can be at most an actor instance, but not an actor.
  • 6. Page 4 Question 8. The guideline of 7 +/ā€“ 2 submodules per level is considered optimal for the following reason: (a) It reduces the memory requirements of the program (b) It matches approximately the number of distinct concepts that can be handled simultaneously by an average developer (c) It increases the speed of the program (d) It appeals to the subjective taste of the average developers (e) None of the above Answer: (b). Psychological/cognitive considerations are the basis for many guidelines for improving productivity in software engineering. This particular guideline has nothing to do with program performance or memory requirements, and there is nothing subjective about it. Controller Model subscriber notifier initiator * repository1 1 * View Question 9. Which of the following can be a sequence of events involved in the MVC architecture, according to the class diagram above: (a) A Model object sends an event to a View object, which notifies a Controller object (b) A View object sends an event to a Model object, which notifies a Controller object (c) A Controller object sends an event to a Model object, which notifies several View objects (d) All of the above (e) None of the above Answer: (c). This is the only one consistent with the associations in the diagram and the basic MVC architecture. In some variations of MVC, controllers might ā€œtalk toā€ views, but, even there, views do not ā€œtalk backā€ to controllers. The following two questions refer to the following insertion sort routine. (Array indices start at 1.) routine insertionSort (A) for j = 2 to length of array A // INV: ... key = A[j] i = j ā€“ 1 while i 0 and A[i] key do A[i + 1] = A[i] i = i ā€“ 1 end while A[i + 1] = key end for
  • 7. Page 5 Question 10. Assume the insertionSort routine is used internally by a program. Which of the following pre- and post-condition pairs is the most appropriate for insertionSort from a maintainability viewpoint? (a) Pre: none; post: array is sorted (b) Pre: array is not sorted; post: array is sorted (c) Pre: array has at least one element; post: array is sorted (d) Pre: array has at least two elements; post: array is sorted (e) Pre: array reference is non-null; post: array is sorted Answer: (e). As per tutorial, array references can (and should) be constrained by assertions. Option (a) is a close call but Option (e) is more appropriate. Question 11. Which of the following assertions is valid each time the program reaches the line ā€œINVā€? (a) Items 1 through j are sorted (b) Items 1 through j ā€“ 1 are sorted (c) key equals A[j] (d) i equals 0 (e) j equals 1 Answer: (b). All other options can be invalidated at some iteration of the loop. Question 12. Keeping CRC cards to the size of 4x6 inches is considered important because: (a) Software engineers prefer even numbers and inch measurement units (b) This size allows just enough space to describe a class of optimal complexity in large script (c) This size is conducive to optimal performance in implementing an object-oriented program (d) All of the above (e) None of the reasons above Answer: (b). For this reason, some software developers actually feel very strongly about 4ā€X6ā€ CRC cards. Options (a) and (c) are ludicrous. Question 13. Which of the following applies to the statement ā€œIf class X uses defensive programming in each method, then good programming practice recommends that any subclass Y that inherits from X should also use defensive programming in each methodā€ (a) Always true (b) Always false (c) It depends on whether or not the subclass is used at the boundary of the system (d) It depends on whether the class invariant of Y is stronger than that of X or the same (e) None of the above Answer: (d). Option (a) is close but not quite right. If class X uses defensive programming in method M then method M accepts any values for the parameters and the class fields. The Liskov Substitution Principle (LSP) requires that class Y has method M that can also take any values for the parameters. However, the invariant of class Y could be stronger, in which case method M can make certain assumptions regarding the values of the
  • 8. Page 6 class fields, without violating the LSP as long as proper encapsulation avoids direct access to the objectā€™s fields. The LSP is an excellent rule of thumb for using inheritance. Question 14. You are developing a command-line user interface. Which of the following design patterns is the most likely to make it easy to add new commands in later versions of the program? (a) Command (b) Composite (c) Observer (d) Strategy (e) Proxy Answer: (a). The Command pattern is used specifically for the purpose of making it easy to add new commands. Question 15. Which of the following checks is LEAST likely to detect maintainability problems in an object- oriented design? (a) Tracing in the class diagram one scenario for each use case (b) Tracing each design element to a functional requirement (c) Checking that none of the design elements can be removed (d) Checking for naming conflicts (e) Using calibrated stubs to predict performance Answer: (e). Calibrated stubs will detect performance problems but not maintainability problems. Tracing scenarios in the class diagrams and checking for naming conflicts will detect inconsistencies; tracing design elements and checking for removable design elements will detect redundancies. Inconsistency and redundancy lead to poor maintainability.
  • 9. Page 7 SECTION II ā€“ ESSAY-TYPE QUESTIONS WRITE YOUR ANSWERS IN THE ANSWER BOOKLET Question 16. (Requirements, analysis) You are developing ThumbsUp, a browser for the newest WebBerry, a popular wireless device that has a color display and a mouse wheel, but no keyboard and no mouse. ThumbsUp has the following buttons only: ā€œBackā€, ā€œForwardā€, ā€œPageā€, and ā€œExitā€, in this sequence. Initially, ThumbsUp is in the ā€œbuttonsā€ mode of operation, where moving the wheel cycles through the buttons in the sequence above, and clicking the wheel activates the selected button. As usual, buttons ā€œBackā€ and ā€œForwardā€ move back and forward through a list of recently visited web pages, and button ā€œExitā€ exits the browser. Button ā€œPageā€ makes the browser go into the ā€œpageā€ mode of operation where moving the wheel cycles through the hyperlinks on the currently displayed web page and double- clicking the wheel activates the selected hyperlink and loads and displays a new web page. Triple-clicking the wheel goes back to the ā€œbuttonsā€ mode. The default selections on entry to the ā€œbuttonsā€ and ā€œpageā€ modes are the ā€œBackā€ button and the first hyperlink of the current page, respectively. The screen scrolls automatically in the ā€œpageā€ mode to keep the current link within the viewable area. Each time ThumbsUp starts, it displays the home page of WebBerryWorld.com, which has hyperlinks to several major web directories. (a) Draw a use case diagram for ThumbsUp. Be sure to cover both stated and implied requirements and give self-explaining names to the diagram elements. [10] User HttpServer PageRestore Back LoadPage Forward LoadStartPage Exit ButtonsMode include include PageMode include include (b) Draw a sequence diagram for a scenario to visit 3 web pages (including the home page), then go back 1 web page, then go forward 1 web page to the last page visited. [10]
  • 10. Page 8 :WheelCtrl :ThumbsUp move :User WebBerryWorld move selectForwardButton getPage loadWebPage selectBackButton selectPageButton pressPageButton click selectHyperlink move activateHyperlink double click getPage HttpServer1 HttpServer2 selectHyperlink move activateHyperlink double click getPage triple click selectBackButton displayPage(page1) move selectForwardButton displayPage(page2) page1 page2 (c) Briefly describe how the requirements above may be changed to make them simpler, easier to implement, and more useful to the user. Keep your description within 1/2 page maximum. Focus on the main functional requirements only; do NOT discuss non-functional requirements, error conditions or secondary flows. Hint: Try to make the user interaction with the browser more uniform. [5] As discussed at the lectures, keeping requirements consistent provides better usability and learning curve for the users AND a simpler system with more general modules and fewer special cases. To avoid inconsistencies between the clicking rules for the buttons and the hyperlinks, hyperlinks should be selected by a single click in the page mode, just like the buttons are selected in the buttons mode. There should be some way of returning to the buttons mode, and the simplest way is by double clicking. (Frequent operations should have simple commands.) Further, for consistency of clicking rules, we can do away with the ā€œPageā€ button and use a double click to go to the page mode. An option is to keep the ā€œPageā€ button but also allow switching to the page mode by double click. Another possibility is to have a single loop of buttons and hyperlinks. However, that might make it more difficult to navigate back to the buttons. We can use double clicking instead of triple clicking to go to the Back button from any hyperlink. Question 17. (Design) You are developing WareStar, a software system for tracking warehoused computer subsystems. Subsystems can be assembled on site from parts and from other warehoused subsystems. Subsystems can be removed from WareStar by a user. When the number of subsystems of a certain type falls below a predetermined lower limit, WareStar schedules assembly orders (in-house) or supply orders (to manufacturers) to replenish the inventory up to a predetermined upper limit. (a) Draw a class diagram for a high-level design model for WareStar. Hint: use the Composite pattern. [10]
  • 11. Page 9 recursively remove and order subsystems UI SubSys qty, onOrder, LL, UL addQty removeQty order * Part order CompositeSubSys order * StockCtrl subSys qtyUpdate updateStock checkLowerLimit 1 create OrderCtrl subSys qty issueOrder Order Qty issue SupplyOrder issue AssemblyOrder issue * ManufacturerInfo contactInfo sendOrder create SubSysCatalog newSubSys retrieveSubSys OrderDBAdaptor recordOrder 1 * 1 * 1 * 0..1 1 1 * 1 * 1 1 1 * create issue Inventory ControlBoundary Orders create (b) Draw a statechart representing the lifecycle of a subsystem type maintained by WareStar, to clarify at least the following issues: creation of the type, ordering from the manufacturer, reaching the lower control limit. Make sure this statechart is consistent with the methods in the class diagram in Part (a). [5] Low StocknewSubSys order On Order addQty Full Stock removeQty Check LL [qty=LL] [qtyLL] (c) State any invariants on the data structures involved in Part (a). [5] Invariants: (LL = qty + onOrder = UL) The ā€œmanufacturerā€ is the same for all SupplyOrder-s that are issued by the same SubSys The components of a subsystem are always the same as on creation of that subsystem.
  ēæ»čƑļ¼š