A Computer Science Tapestry, second edition

ISBN: 0072322039

( first edition web page)

Solutions to end-of-chapter exercises. You'll need a login and password. The password from the first edition still works. A new login/password works too, the same pair that Stuart Reges uses for his information. To get the login/password send me email and "proof" you're a teacher [web address, phone number, personal testimony that you don't lie, etc.]

The second edition of A Computer Science Tapestry: Exploring Computer Science and Programming with C++, published by McGraw-Hill, will be available for use in the fall semester of 1999.

All the chapters are accessible here here in pdf format. Not all these chapters have been through final copy-edit/proof-reading, but they're complete except for small changes to respond to corrections.

Please do not print these pages, they're here for viewing online.

Code is also accessible in formats for Windows and Linux/Unix platforms. The windows code should work on Macintoshes, let me know if there's a problem.

McGraw-Hill will send potential users page-proofs, please contact Emily Lupash at McGraw-Hill for details.

new link to all figures, one per page

New link to data files (hamlet.txt, etc.)

New Power point/Overhead slides

Pause and Reflect answers

The graphics library has its own page.

linux version of graphics library (beta/alpha)

Table of Contents Howto Contents
  1. Computer Science and Programming
  2. C++ Programs: Form and Function
  3. Program Design and Implementation
  4. Control, Functions, and Classes
  5. Iteration with Programs and Classes
  6. Classes, Iterators, and Patterns
  7. Class Interfaces, Design, and Implementation
  8. Arrrays, Data, and Random Access
  9. Strings, Streams, and Operators
  10. Recursion, Lists, and Matrices
  11. Sorting, Templates, and Generic Programming
  12. Dynamic Data, Lists, and Class Templates
  13. Inheritance for Object-Oriented Design
  1. How to: use basic C++, syntax, and operators
  2. How to: format output and use streams
  3. How to: use the class string
  4. How to: understand and use const
  5. How to: overload operators
  6. How to: understand and use standard libraries
  7. How to: understand and use Tapestry classes
  8. How to: use the graphics clases in canvas.h
  9. How to: cope with C++ environments

Chapters

Data files

The data files referred to in the text are browsable here

Code

This code has been tested under Visual C++ and Metrowerks Codewarrior, here's a zip file of programs, windows format and here's a directory for browsing individual files.

Library

These are the files I put in the library we use in our courses. There's no reason to put all the .cpp files in the library. If you don't make a library, you can add these .cpp files to your project and just change the file(s) in the project that students write (the one with main in it and supporting files if any).

For Linux/Unix use this compressed tar file which includes a Makefile for creating a libtapestry library to link with programs. Note, with g++ 2.91 the CList class doesn't compile, but it does compile with 2.95, these are the compilers I tested with.

If you're using the Sun CC compiler, try this compressed tar file, but note that bool is not built-in and I haven't tested everything. There isn't a standard STL like string class, so I built this using "tstring.h"

For core tapestry files and graphics files, including projects for creating libraries under Visual C++ and Metrowerks Codewarrior, see the TOOGL home page.


Owen L. Astrachan
Last modified: Fri Sep 13 10:04:32 EDT 2002