《软件工程》期中试题解答.docx
《《软件工程》期中试题解答.docx》由会员分享,可在线阅读,更多相关《《软件工程》期中试题解答.docx(12页珍藏版)》请在冰豆网上搜索。
![《软件工程》期中试题解答.docx](https://file1.bdocx.com/fileroot1/2023-4/16/4d0302fd-7811-4513-af20-f15aecbd61e2/4d0302fd-7811-4513-af20-f15aecbd61e21.gif)
《软件工程》期中试题解答
《软件工程》期中试题
一、选择题:
1.Thewaterfallmodelofsoftwaredevelopmentisalsoknownasthe()A
A.ClassicallifecyclemodelB.Fountainmodel
C.SpiralmodelD.Chaosmodel
2.Theincrementalmodelofsoftwaredevelopmentis()B
A.Areasonableapproachwhenrequirementsarewelldefined.
B.Agoodapproachwhenaworkingcoreproductisrequiredquickly.
C.Thebestapproachtouseforprojectswithlargedevelopmentteams.
D.Arevolutionarymodelthatisnotusedforcommercialproducts.
3.COCOMOIIisanexampleofasuiteofmodernempiricalestimationmodelsthatrequiresizinginformationexpressedas()D
A.functionpointsB.linesofcodeC.applicationpointsD.anyoftheabove
4.Aneffectiveriskmanagementplanwillneedtoaddresswhichofthefollowingissues()D
A.riskavoidanceB.riskmonitoring
C.contingencyplanningD.alloftheabove
5.Therelationshipsshowninadatamodelmustbeclassifiedtoshowtheir()C
A.WidthanddepthB.Directionalityandreliability
C.cardinalityandmodalityD.probabilityandrisk
6.Thedatadictionarycontainsdescriptionsofeachsoftware()B
A.configurationitemB.dataobjectC.diagramD.notation
7.Thestatetransitiondiagram()A
A.indicatessystemreactionstoexternalevents
B.depictsrelationshipsbetweendataobjects
C.depictsfunctionsthattransformthedataflow
D.indicateshowdataaretransformedbythesystem
8.Whichofthefollowingisnotanareaofconcerninthedesignmodel()D
A.architectureB.dataC.interfacesD.projectscope
9.Aprogramdesignlanguage(PDL)isoftena()A
A.combinationofprogrammingconstructsandnarrativetext
B.legitimateprogramminglanguageinitsownright
C.machinereadablesoftwaredevelopmentlanguage
D.usefulwaytorepresentsoftwarearchitecture
10.Whattypesoferrorsaremissedbyblack-boxtestingandcanbeuncoveredbywhite-boxtesting()B
A.behavioralerrorsB.subtlelogicerrorsC.performanceerrorsD.inputerror
11.ToachievehighmodularityofsoftwarecomponentsyouneedC
A.highcouplingandhighcohesion
B.highcouplingandlowcohesion
C.lowcouplingandhighcohesion
D.lowcouplingandlowcohesion
12.WhichofthefollowingisnotanobjectiveforbuildingananalysismodelC
A.definesetofsoftwarerequirements
B.describecustomerrequirements
C.developanabbreviatedsolutionfortheproblem
D.establishbasisforsoftwaredesign
13.下图所示的软件模块结构图,该软件的宽度为()。
D
A.1B.3C.5D.6
14.面向对象的软件工程中,识别主类主要靠()。
A
A.经验B.技巧C.启发式规则D.面向对象分析理论
15.用例图是()。
D
A.系统特定行为的描述
B.系统行为之间交互的描述
C.系统和外部实体交互的描述
D.系统特定行为和外部实体以及和其他行为交互的描述
二、简答题:
1.Whatarethedifferencesbetweengenericsoftwareproductdevelopmentandcustomsoftwaredevelopment
A:
Theessentialdifferenceisthatingenericsoftwareproductdevelopment,thespecificationisownedbytheproductdeveloper.Forcustomproductdevelopment,thespecificationisownedbythecustomer.Ofcourse,theremaybedifferencesindevelopmentprocessesbutthisisnotnecessarilythecase.
2.Whatarethefourimportantattributeswhichallsoftwareproductsshouldhave
A:
Forimportantattributesaremaintainability,dependability,efficiencyandusability.
3.Asoftwarearchitecturedescribesahigh-leveldesignviewofasoftwaresystem.Whataretheadvantagesofexplicitlydescribingthearchitectureindependentlyfromtheimplementation
参考答案(不够准确):
Thearchitecturemayhavetobedesignedbeforespecificationsarewrittentoprovideameansofstructuringthespecificationanddevelopingdifferentsub-systemspecificationsconcurrently,toallowmanufactureofhardwarebysub-contractorsandtoprovideamodelforsystemcosting.
4.Explainwhyitisimportanttoproduceanoveralldescriptionofasystemarchitectureatanearlystageinthesystemspecificationprocess.
A:
Anoverallarchitecturaldescriptionshouldbeproducedtoidentifysub-systemsmakingupthesystem.Oncethesehavebeenidentified,theymaybespecifiedinparallelwithothersystemsandtheinterfacesbetweensub-systemsdefined.
5.Requirementsshouldstatewhatasystemshoulddo,withoutstatinghowitshoulddoit.Whyisthisdistinctionuseful
6.Defineblackboxandwhiteboxtesting.WhataretheadvantagesofeachapproachWhyarebothnecessary
7.Fullpathcoveragetestingrequiresthateverypossiblepaththroughthecodebetestedatleastonce.WhyisfullpathcoveragetestingdesirableForthecodefragmentabove,howmanytestcaseswouldbeneededforfullpathcoverageWhymightfullpathcoveragebeimpossibletoachieveforsomeprograms
8.WhyissoftwaremaintenancedifficultWhyisitnecessary
9.Ifyouwantdevelopaninteractivesystemthatallowsrailwaypassengerstofindtraintimesfromterminalsinstalledinstations,whichgenericsoftwareprocessmodelthatmoresuitabletomanagementthedevelopmentprocessAndwhy
A:
InteractivetimetableSystemwithacomplexuserinterfacebutwhichmustbestableandreliable.Shouldbebasedonthrow-awayprototypingtofindrequirementstheneitherincrementaldevelopmentorwaterfallmodel.
10.Describefourtypesofnon-functionalrequirementsthatmaybeplacedonasystem.Giveexamplesofeachofthesetypesofrequirement.
A:
Therearemanypossibilitieshere.SomesuggestionsareshowninFigure.
FigureNon-functionalrequirements
Non-functional
requirement
Description
Description
Performance
Performancerequirementsset
outlimitstotheperformance
expectedofthesystem.These
maybeexpressedindifferent
waysdependingonthetypeof
system.numberof
transactionsprocessedper
second,responsetimetouser
requests,etc.
Thesystemmustprocessatleast150
transactionspersecond.
Themaximumresponsetimeforanyuser
requestshouldbe2seconds.
Implementation
Definesspecificstandardsor
methodswhichmustbeusedin
thedevelopmentprocessforthe
system
Thesystemdesignmustbedevelopedusing
anobject-orientedapproachbasedonthe
UMLprocess.
ThesystemmustbeimplementedinC++,
Version.
Usability
Definesrequirementswhich
relatetotheusabilityofthe
systembyend-users.
Alloperationswhicharepotentially
destructivemustincludeanundofacility
whichallowsuserstoreversetheiraction.
(Thisisanexampleofafunctional
requirementwhichisassociatedwithanonfunctional
requirement)
Alloperationswhicharepotentially
destructivemustbehighlightedinredinthe
systemuserinterface.
Safety
Safetyrequirementsare
concernedwiththeoverallsafe
operationofthesystem
Thesystemmustbecertifiedaccordingto
HealthandSafetyRegulationsXYZ123.
三、综合题
1.Thefollowingtableshowstheestimatedactivitydurationsandpre-requisitesforaprojectdevelopment.
Activity
Description
Duration(weeks)
TaskPre-requisites
T1
RequirementsElicitation
4
T2
Analysis&Design
3
1
T3
Installhardware
2
1
T4
DesignReview
1
2
T5
Code&UnitTest
4
1,2,3,4
T6
IntegrationTest
2
5
T7
PortingSoftware
1
4,6
T8
Documentation
2
6,7
T9
AcceptanceTest
3
5,6,7
T10
Install&Train
2
9
Drawaactivitycharttodeterminetheearliestweekofcompletion,theactivitieswhichhavesomefloatorslack,andtheactivitiesonthecriticalpath.Drawabarchartshowingtheprojectschedule.
2.绘制打电话的状态转换图
3.某校教务系统具备以下功能,输入用户ID号及口令后,经验证进入教务管理系统,可进行如下功能的处理:
查询成绩:
查询成绩以及从名次表中得到名次信息。
学籍管理:
根据学生总成绩排出名次信息。
成绩处理:
处理单科成绩并输入成绩表中。
就以上系统功能画出0层,1层的DFD图。
教务系统0层DFD图
教务系统1层DFD图
(身份验证处理框对应有一个用户信息的存储,名次表和学生成绩表应用存储的表示法)
4.一个自动化图书馆目录的软件系统要被开发。
这个系统将要包含图书馆中所有图书的信息,要求该系统对图书管理员、借阅者和读者都可用。
该系统应该支持目录浏览、查询,允许用户发送消息给图书管理员预订一本在借图书。
识别出系统描述中应考虑的基本视点,并用视点继承图(层次图)来描述它们之间的关系。
6版题
A:
TheviewpointsareshowninFigure.Notethatsystemmanagement.those
responsibleforinstallingandmaintainingthecomputersystemareaviewpointas
wellaslibrarystaffandlibraryusers.Libraryusershavebeenseparatelyidentifiedas
browsersandsearchersastheseoperationstypicallyrequiredifferenttypesofservices.
FigureViewpointhierarchydiagram
5.Developanobjectmodel,includingaclasshierarchydiagramandanaggregationdiagramshowingtheprincipalcomponentsofapersonalcomputersystemanditssystemsoftware.
A:
Therearemanypossibleorganizationsfortheclasshierarchy.IshowasimpleoneinFigurewithonlytwolevels.Athree-levelhierarchywouldalsobeOKbutmorethanthatwouldbetoomuch.Theaggregationdiagramshowsthepart-ofrelationshipsbetweenobjects.ThisisshowninFigure.Obviously,furtherdecompositionofthelowestlevelispossible.
FigureClasshierarchyforaPC
FigAggregationdiagramforaPC
6.Developasequencediagramshowingtheinteractionsinvolvedwhenastudentregistersforacourseinauniversity.Coursemayhavelimitedenrolment,sotheregistrationprocessmustincludechecksthatplacesareavailable.Assumethatthestudentaccessesanelectroniccoursecataloguetofindoutaboutavailablecourses.
A:
SeeFigure.
FigureSequencediagramofcourseregistration
7.Whatisthefundamentaldifferencebetweenafat-clientandathin-clientapproachtoclient-serversystemsdevelopment
A:
Inafat-clientsystem,someoftheapplicationprocessingiscarriedoutontheclientwhereasinathinclientsystemonlytheuserinterfaceisdisplayedontheclientandalloftheapplicationprocessingiscarriedoutontheserver.
8.UsingtheUMLgraphicalnotationforobjectclasses,designthefollowingobjectclassesidentifyingattributesandoperations.Useyourownexperiencetodecideontheattributesandoperationsthatshouldbeassociatedwiththeseobjects:
Aprinterfora