Revised November 19/13

CS 246: Object-Oriented Software Development


General description

This course introduces students to basic UNIX software development tools and object-oriented programming in C++ to facilitate designing, coding, debugging, testing, and documenting medium-sized programs. Students learn to read a specification and design software to implement it. Important skills are selecting appropriate data structures and control structures, writing reusable code, reusing existing code, understanding basic performance issues, developing debugging skills, and learning to test a program.

Logistics

Audience

  • 2A Computer Science students

Normally available

  • Fall, Winter, and Spring

Related courses

  • Predecessors: CS 136 or 138 (with at least 60%), CS 145 (before Fall 2011), or CS 146 (programming in C)
  • Successors: CS 240 and CS 241 (and then most CS upper-year courses)
  • Co-requisites: Courses that develop strong programming skills and the ability to use tools to create software

For official details, see the UW calendar.

Software/hardware used

  • Unix, C++

Typical reference(s)

  • C++ Primer (5th edition), by Stanley B. Lippman, Josée Lajoie and Barbara E. Moo, Addison-Wesley, 2012.
  • Absolute C++ (6th edition), by Walter Savitch and Kenrick Mock, Pearson, 2015.

Required preparation

At the start of the course, students should be able to:

  • Design, implement, test, and debug C programs to solve problems requiring less than a hundred lines of code using types, variables, arrays, structures, loops, conditionals, procedures, functions, and dynamic memory
  • Explain basic properties of the C memory model: bytes vs. words, memory as an array, run-time stack and stack frames, memory allocation on the heap vs. automatic allocation on the stack, pointers as memory addresses

Learning objectives

At the end of the course, students should be able to:

  • Design, implement, test, and debug C++ programs to solve problems requiring hundreds of lines of code, making appropriate use of
    • types, variables, arrays, strings, and dynamic memory; loops, conditionals, and other control structures; structures, unions, and enumerations; procedures and functions; the preprocessor; formatted and unformatted I/O
    • classes, objects, overloading, and single inheritance
    • a subset of the STL, including vector, list, and map
    • assertions and exceptions
    • basic software development tools, including makefiles, a shell, a revision control system, and a debugger
    • test suites for unit testing, white and black box testing
    • structured programming, incremental development
    • interface design, abstractions, information hiding, cohesion and coupling
    • a subset of UML to specify classes, objects and relationships between them
    • a selection of design patterns, including adapter and template
  • Explain the following properties of the memory model used in C++, including their impact on time and space efficiency when designing code: bytes vs. words, memory as an array, run-time stack and stack frames, memory allocation on the heap vs. automatic allocation on the stack, pointers as memory addresses, the representation of objects in memory
  • Define and explain at an elementary level basic software-engineering concepts, including the water-fall model and other development methodologies

Typical syllabus

Shell (4 hours)

  • File system, pattern matching, quoting, shell/system commands, file permission, redirection, shell programming

C++ (16 hours)

  • Declarations, expressions, control structures, structured programming, preprocessor, I/O, dynamic allocation, objects, overloading, inheritance, templates, STL, separate compilation

Unix tools (8 hours)

  • Compiler, debugging and the debugger (e.g., GDB), code management (e.g., make), version control (e.g., SVN)

Software engineering (8 hours)

  • Development process, design (UML), language selection, patterns, testing