CHow to Programdoc.docx

上传人:b****8 文档编号:29826255 上传时间:2023-07-27 格式:DOCX 页数:21 大小:25.89KB
下载 相关 举报
CHow to Programdoc.docx_第1页
第1页 / 共21页
CHow to Programdoc.docx_第2页
第2页 / 共21页
CHow to Programdoc.docx_第3页
第3页 / 共21页
CHow to Programdoc.docx_第4页
第4页 / 共21页
CHow to Programdoc.docx_第5页
第5页 / 共21页
点击查看更多>>
下载资源
资源描述

CHow to Programdoc.docx

《CHow to Programdoc.docx》由会员分享,可在线阅读,更多相关《CHow to Programdoc.docx(21页珍藏版)》请在冰豆网上搜索。

CHow to Programdoc.docx

CHowtoProgramdoc

TOUROCOLLEGECOURSESYLLABUS

LANDERCOLLEGE

DEPARTMENT:

ComputerScience

COURSETITLE:

DataStructures

COURSENUMBER:

MCO242

PREREQUISITES:

MCO232

CREDITHOURS:

3

DEVELOPER:

MiriamPlonczak

LASTUPDATE:

July2003

COURSEDESCRIPTION

ThiscourseexploresthemoreadvancedconceptsoftheObjectOrientedDesignandProgrammingparadigmincludingoperatoroverloading,inheritanceversuscomposition,polymorphism,run-timeversuscompiletimebinding,multipleinheritance,shallowversusdeepcopying,exceptionhandling,andfunctiontemplates.Inaddition,thebasicfileI/Ooperationswillbecovered.Somebasicdatastructuressuchasstacksandqueuesmaybeintroducedaswell.Studentswilldevelopapplicationsthatimplementtheseobject-orientedconceptsusingC++.

COURSE/DEPARTMENTALOBJECTIVES

Thestudentswillbeableto:

Explainwhenstaticdatamembersareusedandhow

Differentiatebetweenclassstaticdatamembersandclassdatamembers

Giveanexampleofanoverloadedoperatorandexplainhowoverloadedoperatorsareusedtomakeclassesactlikebuiltindatatypessuchasintandfloat

Developcodethatimplementsavarietyofoverloadedoperatorsforaparticularclass

Usememorymanagementtechniquessuchasdynamicmemoryallocation,releasingdynamicallyallocatedmemory

Manipulatestringsinavarietyofways:

usingcharactersarrays,usingchar*pointers,usingtheC++stringclass

Differentiatebetweenthedifferentwaysstringscanbemanipulatedandidentifytheadvantagesanddisadvantagesofeachtechnique

UseC++libraryfunctionstohandleC-stringssuchasstrlen(),strcpy(),strcat(),strcmp(),strstr()

Explainwhatismeantbymemberwisecopyandwhatproblemsitmightcause

Explainhowcopyconstructorssolvetheproblemofmemberwisecopy

Demonstratewhencopyconstructorsarenecessary

Differentiatebetweenacopyconstructorandaconvertconstructor

Explainwhenclassdestructorsarenecessary

Differentiatebetweenaconvertconstructorandobjectconversionusingtheoverloaded

DefinethefollowingOOPconcept:

composition

DefinethefollowingOOPconcepts:

inheritance,polymorphism

ExplainhowtheconceptofinheritanceisimplementedusingC++

Explainhowinheritanceandcompositionprovidescodereusability

Compareandcontrastcompositionandinheritance

Demonstratehowpolymorphismisimplementedusinginheritancewithvirtualfunctions

Compareandcontrastprivateversuspublicinheritance

Identifytheaccessibilityofdatamembersandmemberfunctionsthatweredeclaredprivate,public,orprotectedtoclassmemberfunctions,toinheritedclassmemberfunctionsandtooutsidememberfunctions

Explaintheadvantageofusingprotecteddatamemberswithinaninheritancehierarchy

Identifytheorderinwhichconstructorsanddestructorsareinvokedwhenderivedclassobjectsareinstantiated

Identifythepitfallsofmultipleinheritanceandhowtheycanbeaddressed

Explainhowinheritancecanbeusedtospecializeorgeneralizeabaseclass

Explainhowinheritancecanbeusedtohidedatamembersand/ormemberfunctionsofabaseclass

Listtheadvantagesanddisadvantagesofdynamicversusstaticbinding

ExplainhowdynamicbindingisimplementedinC++usingvirtualmethods

Explainanddemonstratewhyvirtualdestructorsmightbenecessaryifdynamicmemoryallocationtakesplaceswithinabaseandderivedclass

ListseveralreasonsthatC++allowsustodefinefriendfunctions

Usetheifstreamandofstreamobjectstoaccess,processandstoredataondiskfiles

Identifyfstreamclassmemberfunctionsandhowtheyareused:

open(),is_open(),operator!

(),fail(),eof()

Explainwhyitisimportanttocloseafilewhenitisnotbeingused

Differentiatebetweentextfilesandbinaryfileformats

Differentiatebetweensequentialfileandrandomfileprocessing

Explainwhydelimitersarenecessaryinordertoprocesstextfilesandwhyblankscannotalwaysbeusedasdelimiters

Developcodethatimplementsexceptionhandlingtechniquesusingtry,catchandthrow

Explainwhydesigningaclassthatthrowsexceptionsmaybemorepreferablethandisplayingerrormessagesonthescreen.

Explainhowusingtemplatesallowsustoimplementgenericclassesorgenericfunctions

Explainwhytheimplementationofoperatoroverloadingisintrinsictotheuseofmanytemplates

Givenspecificationsofaclass,writeC++codenecessarytoimplementaclass,includingdefault,copy,andconvertconstructors,destructors,memberfunctions,overloadedoperators,variouslevelsofaccessibility(public,privateandprotected)

DemonstratehowC++implementsinheritancebydefiningbasedandderivedclasses

Givenahierarchyofclasses,identifywhichdatamembersandmemberfunctionsareaccessiblebasedontheaccess-specifierusedwhenthederivedclassisininheritedfromthebaseclass

COURSE/INSTITUTIONALOBJECTIVES

Thiscourseisintendedtofine-tunetheanalyticalandtechnicalskillsstudentsneedtofunctioninourincreasinglytechnologicalsociety.ThiscourseprovidesstudentswithextensiveexperienceindevelopinganddebuggingcomplexC++codetosolvecomplicatedbusinessandmathematicalproblems.Itservestopreparethestudenttopursueacareerinthehighlycompetitivefieldsofcomputerprogrammingand/orsystemsanalysis.

COURSECONTENT

Gaddisbook:

Chapters7,11,12,13,14,15

Deitelbook:

Chapters7,9,10,12,13,14,20,21(Section21.7)

Classes

Compareandcontrastdifferenttypesofconstructors

Explaintheimportanceandsignificanceofusingheaderinitialization

get()andset()methods–whyaretheynecessary?

inlinefunctions–whatadvantagedotheyprovide?

Whatarethelimitations?

Introduceconceptsofdatahidingandencapsulation

Explainhowoverloadedfunctionsareidentifiedwithargumentsignatures

Demonstratehowtoinvokememberfunctionsto"sendmessages"toaninstanceofaclass

Usepointerstoclassobjects

Explainwhentousestaticdatamembersandstaticmemberfunctionsandhowtheydifferfromregulardatamembersandmemberfunctions

Giveexamplesoffunctionsandclassesthatmightbedeclaredfriendsofotherclassesandexplainwhy

DynamicMemoryAllocationandMemoryManagement

Discussmemorymanagementprovidedbycstringfunctions.Whyisthe'\0'soimportant?

Discusshowmemoryismanagedwhenstructsandclassesareused.Howisamemberwisecopyperformed?

Whatisthedifferencebetweenadeepandshallowcopy?

Dynamicmemoryallocation-howandwhyisitused?

Howandwhythecopyconstructorandoverloadedassignmentoperatorareusedforclassesthatperformdynamicmemoryallocation

Explainhowtousethethispointer

OperatorOverloading-ConceptsandImplementation

overloadingthe+,-,++(postfixandprefix)

overloadingrelationaloperators

overloadingstreaminsertionandextractionoperators

overloadingthe[]operator

conceptofoperatorstacking

objectconversionusingconvertconstructorsandoverloadedcastoperator

creatingastringclassthatsupportsoverloadedoperators

Objectcomposition-conceptandimplementation

Demonstratehowobjectcompositionallowsustoreusecode

Demonstratewhytheouterobjectmustprovideadditionalmethodstoallowaccesstotheobjectsthatitcontainssincetheirmethodsandattributesarehiddenfromoutsideview

Showhowauserinterfaceswithjusttheouterclassandhowthatclasspassesalongthemessagestotheobjectsitcontains.

CharacterManipulation

datavalidation

charactercaseconversion

I/Ousingcharacterarraysandthecinobject

libraryfunctionsthatmanipulate"strings"

string/numericconversion

usingtheC++stringclass

Inheritance

Whatisinheritance,when,howandwhyitisused

Whateffectdoesaccessspecificationhave?

public,private,andprotected

Whendoweuseeachtypeofspecification?

constructorsversusdestructorsinaninheritancehierarchy

Functionoverridingversusfunctionoverloading

Whatispolymorphism,whyandhowisitimplementedinaninheritancehierarchy?

Differentiatebetweenearlybindingandlatebinding.Enumerateadvantagesofeach.

Whatisavirtualfunction,howisitimplementedandwhatpurposedoesitserve

Whatisapurelyvirtualfunction

HowisRTTIusedwithpolymorphismtoidentifytypeswithinaninheritancehierarchy

Howisdynamiccastingusedtoconvertobjectswithinaninheritancehierarchy

Whatisanabstractbaseclass,howisitimplementedandwhymightitbeused?

Whatarethedrawbacksofmultipleinheritance,howaretheyhandledincodeandwhyismultipleinheritanceused

SequentialFileProcessing

Whatisafileandhowisitaccessed?

Storingtextdataonafile:

howisdatastoredandretrieved

Howisnumericdatastoredinatextfile

candatawithinatextfilebemodified?

Howisatextfile"modified"ifdatachanges?

Whymustdelimitersbeused?

Isusingablankasadelimiteralwaysagoodchoice?

Whyisexceptionhandlingespeciallyimportantwhenprocessingfiles?

Howdowecheckforandaddressfileerrorconditions?

Whatkindoferrorconditionsshouldweanticipate?

Howcanfilesbeusedbyclassconstructorsanddestructorstoimplementobjectpersistence?

RandomFileAccess

Howdoesbinarydatadifferfromtextdata

usingstructstocreatefixedlengthrecords

Howistextandnumericdatastoreddifferentlyinrandomfilesthaninsequentialtextfiles?

Considerabusinesscasestudythatimplementsabusinessapplicationusingrandomfileprocessing

input/outputofobjects

Exceptionhandling

whatisexceptionhandlingandwhenshoulditbeused

identifyingexceptionconditions

throwingexceptionsinsteadofdisplayinganerrormessage

handlinganexceptionusingthetryandcatchclauses

rethrowinganexception

usingthelibrar

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 表格模板 > 合同协议

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1