Reliable Data Structures in C

Thomas Plum

Publisher: Plum Hall, 1985, 253 pages

ISBN: 0-911537-04-X

Keywords: Programming

Last modified: March 20, 2022, 11:08 p.m.

This book covers all the advanced features of C with examples to illustrate their usefulness. Sophisticated constructs like pointers to functions, bit fields, unions, macros, typedefs, conditional compilation, enumerations, self-referential structures, dynamic allocation, and portable file techniques — all are illustrated with practical case studies. General purpose functions and macros are created for classic dynamic data structures like stacks, queues, deques, and trees, along with application-oriented case studies like interactive menu processing and hashed file storage.

A series of reliability rules are presented to assist the programmer in writing programs that deliver "no surprises". Concepts from the ANSI standardization of C point the way to powerful but portable application of the advanced features of C.

  1. Introduction
  2. Preprocessing
    1. Defined Constants
    2. Defined Types
    3. Standard Headers
    4. Macro Functions
    5. Undefining
    6. Conditional Compilation
  3. Scalars
    1. The Math Library, with <math.h>
    2. Error-handling
    3. Character Tests, with <ctype.h>
    4. Boolean Data
    5. Enumeration Types
    6. Range-checking
    7. Signed and Unsigned Arithmetic
    8. Overflow
    9. Data Properties
  4. Arrays
    1. Array Data
    2. Sorting an Array
    3. Strings
    4. Pointers as Array Parameters
    5. Arrays of Strings
  5. Pointers
    1. Declaration of Pointers
    2. Pointers to Scalars
    3. Dangling Pointers
    4. Array Pointers and Strings
    5. Changing Subscripts into Pointers
    6. Multi-dimensional Arrays
    7. Arrays of Pointers
    8. Command Line Arguments
    9. Pointers to Functions
    10. Pointer Transformations
  6. Standard File and Terminal I/O
    1. Formatted Output
    2. Standard Files
    3. Reading Lines of Input
    4. Formatted Input
    5. Direct Terminal I/O
  7. Structures
    1. Records
    2. Structure for Information-Hiding
    3. Properties of Structures
    4. Unions
    5. Bit Fields
    6. Structures of Strings
    7. Pointers to Structures
    8. Example: Menu Processor
    9. A Translator for Menus
  8. Dynamic Data Structures
    1. Dynamic Storage Allocation
    2. Singly-linked Lists
    3. Queues
    4. Deques: Double-Ended Queues
    5. Trees
  9. Files
    1. Standard (Default) Files
    2. Processing named Files
    3. Direct Access and Fseek
    4. Binary I/O
    5. Record I/O
    6. A Record File with Hashed Access
  • Appendix

Reviews

Reliable Data Structures in C

Reviewed by Roland Buresund

OK ***** (5 out of 10)

Last modified: May 21, 2007, 3:20 a.m.

Good, reliable advice. I wish people would read stuff like this.

Comments

There are currently no comments

New Comment

required

required (not published)

optional

required

captcha

required