Announcements and Reminders
• Recitation sessions are being held this week, with focus on introducing students to Unix systems
• You’re responsible for policies listed in the course syllabus
• Class moodle page is now available – can access department moodle site from link in Sweany’s web page
Chapter 1• What is system programming ? • Why Unix ? (section 1.1.2) • Why C ? (section 1.1.3)
• Three “primary” tools (section 1.2)• Shell• Text editor• Debugger
Software Process – Procedural Design
• Course Outcome 6. says “Using a software process model, design and implement a significant software application in C.”
• Waterfall process model (see Wikipedia)
• Procedural design – aka • Hierarchical Design• Top-Down Design• Stepwise Refinement
Design Example – part 1• Design and implement a student database
• Create student database• Add student data• Delete student data• Search for student records • Print student record(s)• Generate “statistics”
Design Example – part 2• Design and implement a “student database”
• Generate “statistics” – e.g. list all first-year students with gpa > 3.14• Parse inquiry• Find data• Perform Set operation(s)• Print inquiry result
Design Example – part 3• Design and implement a “student database”
• Generate “statistics” – e.g. list all first-year students with gpa > 3.14• Parse inquiry
• Read command • Extract set operation from string• Extract set operands from string• Put inquiry in canonical (standard) form • Return canonical form of inquiry
Abstract Data Type (ADT)• Course outcome 3. says “Describe the concept of an
abstract data type (ADT)”• ADT “describes” a new type of data• Includes only two things – a name, and a list of operations• E.G. --- Matrix ADT might include operations
• Create a matrix• Add two matrices giving a new matrix to represent the sum• Multiply two matrices giving a new matrix to represent the product• Invert a matrix• Find the determinant of a matrix• Print a matrix
• Notice that NO implementation details included in ADT
Set ADT• Name – Set• Operations
• Create a set• Print a set• Add element to a set• Remove element from a set• Compute intersection of two sets• Compute union of two sets
Your Turn• Provide an ADT for a “list”
• Provide an ADT for “student database” – or have we already done this?
Top Related