ch1java - Ch 1: Intro to Problem Solving Using ADTs &...

Info iconThis preview shows pages 1–9. Sign up to view the full content.

View Full Document Right Arrow Icon
2001-2009 M. D. Evans All Rights Reserved 1 Ch 1: Intro to Problem Solving Using ADT’s & Objects: 1.1 The Problem Domains: Real world populated by objects ( physical ). attributes + behaviours modeling Conceptual world objects ( conceptual ) templates = attr + behaviours modeling Computer world data containers attr ( data ) + behaviours ( legal opns performed on data )
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2001-2009 M. D. Evans All Rights Reserved 2 1.2 The Solution Domains: Apply the swe & data spec n lifecycles: design Data Algorithms / Procedures ~ High ~ ~ Mid ~ ~ Low ~
Background image of page 2
2001-2009 M. D. Evans All Rights Reserved 3 The Software Engineering Lifecycle: specification of requirements design hi mid low implementation code build test maintenance Example: We are contracted to build software which will maintain SFU course class lists.
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2001-2009 M. D. Evans All Rights Reserved 4 The Data Specification Lifecycle: application / ADT level - decide: data structures level - decide: which data structure to use by analyzing how efficient the opns will be under each structure considered. representation level - decide: how to represent details of the chosen structure in memory. implementation level - decide: all remaining details i.e. id names, packaging… according to chosen lang of impl n .
Background image of page 4
2001-2009 M. D. Evans All Rights Reserved 5 Example: We must identify & design the data objects associated with the s/w which will maintain SFU course class lists. The objects : classList, student, (others??) Their designs : for classList: application level : classListType remove (student) add (student) printWholeClass ( ) : classSize collectionOfStudents
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2001-2009 M. D. Evans All Rights Reserved 6 data structures level : for collectionOfStudents: use a list? a hash table? a binary search tree? for classSize: use an integer? a real? a string? representation level : will the list be linked or an array? implementation level: translate all designs / decisions into java / C++.
Background image of page 6
2001-2009 M. D. Evans All Rights Reserved 7 Important point: Adt = template = collection of data + set of operations Data structure = a specification of the structure of the data container & the set of operations permitting manipulation of this data. i.e you choose a particular data structure when you design how the ADT is to be modeled.
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2001-2009 M. D. Evans All Rights Reserved 8 1.3 Modeling Data: Types, Structures & Abstraction: Def: data type = a set of objects / values (called the domain of the data type) together with a set of operations that can be performed on these objects. we will look at 2 ‘
Background image of page 8
Image of page 9
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 26

ch1java - Ch 1: Intro to Problem Solving Using ADTs &...

This preview shows document pages 1 - 9. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online