# Think C Proramming Fundamentals For The Macintosh 1993 — source transcripts, page 1

[Canonical transcript page](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1)

## Transcribed source material

Machine transcriptions and image descriptions; uncertain copy may be marked [illegible]. Verify against the linked originals. Historical rights remain with the original owners.

These are transcribed excerpts, not the full publications. Open the originals for remaining pages.

### Image 1

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-30b219983805ab9115b1e6e9d7947e73f7cc830e95f3cde8fd99892acd845af0)

Transcribed text:

PRIMA
PRACTICAL PROGRAMMING SERIES
THINK C!™
PROGRAMMING FUNDAMENTALS FOR THE MACINTOSH
COVERS VERSION 6
Includes Macintosh Simulator C – an Innovative Tutorial Program on Two Disks!
• Unleash the Full Power of Your Macintosh – Even if You Are Not a Programmer
• Learn Macintosh Programming Fundamentals Quickly and Easily
• Master the Basics of the THINK C Programming Language from the Ground Up
VALUABLE MAC SIMULATOR C SOFTWARE INCLUDED
PRIMA'S MACINTOSH SERIES
DAN PARKS SYDOW

Image description: A book cover with a green and purple header band, large orange THINK C! title over a glowing close-up of computer keyboard keys showing numbers and letters, with small badge graphics for a software disk and Prima's Macintosh Series apple logo.

Reading notes: The word THINK on the left side of the title is partly overlapped by the large orange T, read as THINK in white tab text. Version 6 is printed as 'VERSION 6' in the orange corner banner, with 'COVERS' above it; the printed date is treated as a version number rather than a calendar date.

Printed product names: THINK C · Macintosh Simulator C

Printed dates: Version 6

Languages: English

[Original Image 1](https://www.vintageapple.net/files/e629a75cae2e56cc40145dc001b6632b12776cbacc943c5b164b9143fed11782/87f2dc72d70d36c38bf7f2b5.webp)

### PDF page 1

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-34d77f8f12b2becb44a64ae654b64a7cdebd72a2c46baa35129c92e351c82bb4)

Transcribed text:

PRIMA
PRACTICAL PROGRAMMING SERIES
THINK C!™
PROGRAMMING FUNDAMENTALS FOR THE MACINTOSH
Includes Macintosh Simulator C – an Innovative Tutorial Program on Two Disks!
• Unleash the Full Power of Your Macintosh – Even if You Are Not a Programmer
• Learn Macintosh Programming Fundamentals Quickly and Easily
• Master the Basics of the THINK C Programming Language from the Ground Up
COVERS VERSION 6
VALUABLE MAC SIMULATOR C SOFTWARE INCLUDED
PRIMA'S MACINTOSH SERIES
DAN PARKS SYDOW

Image description: A book cover with a teal and purple header reading PRIMA, a large orange THINK C! title over a dark green background, and a close-up of glowing keyboard keys labeled with numbers and letters, with two small inset badges at the bottom.

Reading notes: The word THINK appears in white on a purple band to the left of the large orange title and is treated as part of the title; the reading order of this stylized title is approximate. The 'Version 6' badge is read as 'COVERS VERSION 6'. Small badge text is legible but the reading order of the bottom badges relative to the author name is inferred from layout.

Printed product names: THINK C · Macintosh Simulator C

Languages: English

[Original PDF page 1](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=1)

### PDF page 2

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-4098e20d1eaea622817e558ce2c6a0303ac5226bdecada7a8b6a0f6db7cf8a93)

Image description: The image is an entirely blank white page with no visible artwork, layout, or printed content.

Reading notes: No visible text or imagery was found in the scan, so the transcript and all printed fields are empty.

[Original PDF page 2](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=2)

### PDF page 3

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-45f8cd286c6a13bfbffa30fd6fd727a68c016b27ca57344990e1d77e19f97ddd)

Transcribed text:

Think
THINK

Image description: A page with a large IBM-style THINK logo in black and gray, featuring a square with a gradient sphere motif and five diagonal gradient bars running from upper right to lower left, over a mostly blank white page with faint text blocks above and below the logo.

Reading notes: Faint text above the logo (apparently a heading and body paragraphs) and below the logo is too light to transcribe reliably and has been omitted. The word 'Think' appears in lowercase above the all-caps 'THINK' logo wordmark; both are treated as printed headline text. Headline choice is uncertain: 'Think' is the most prominent readable word.

Languages: English

[Original PDF page 3](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=3)

### PDF page 4

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-4ad383837d3b9ebd715ef7186ccb8b617374d48b747f34fbc4d0aec870d11079)

Prima Computer Books

Transcribed text:

Prima Computer   Books
Available Now
WINDOWS Magazine Presents:   Access from the Ground   Up
Advanced PageMaker   4.0   for Windows
DESQview: Everything   You   Need to Know
DOS   6: Everything   You   Need   to   Know
WINDOWS Magazine   Presents.   Encyclopedia for Windows
Excel 4 for Windows: Everything   You   Need to Know
Excel 4 for Windows: The Visual Learning Guide
WINDOWS Magazine   Presents.   Freelance Graphics for Windows: The Art of Presentation
Harvard Graphics for Windows: The Art of Presentation
LotusWorks 3: Everything   You   Need to Know
Microsoft Works for Windows By Example
NetWare 3.x: A Do-It-Yourself Guide
Novell NetWare Lite: Simplified Network Solutions
PageMaker   4.0   for Windows: Everything   You   Need to Know
PageMaker 4.2 for the Mac: Everything   You   Need to Know
PageMaker 5 for Windows: Everything   You   Need to Know
WINDOWS Magazine   Presents.   The   Power   of Windows and   DOS   Together, 2nd Edition
Quattro   Pro   4: Everything   You   Need to Know
QuickTime: Making Movies with   Your   Macintosh
Smalltalk Programming for Windows (with   3¥2"   disk)
Superbase Revealed!
SuperPaint   3: Everything   You   Need to Know
Windows 3.1: The Visual Learning Guide
Word for Windows 2: The Visual Learning Guide
Word for Windows 2 Desktop Publishing By Example
WordPerfect 5.1 for Windows Desktop Publishing By Example
WordPerfect 6 for   DOS:   The Visual Learning Guide
Upcoming Books
CorelDRAW! 4 Revealed!
Improv 2.1 Revealed! (with   3W'   disk)
How to   Order:
Individual orders and quantity discounts are available from the publisher,   Prima   Publishing,
P.O.   Box 1260BK, Rocklin, CA 95677-1260; telephone (916) 786-0426; fax (916) 786-
0488.   If   you are seeking a discount, include information on your letterhead concerning the
intended use of the books and the number of books you wish to purchase.

Reading notes: Garbled characters in '3¥2"' and '3W'' disk' references Ambiguous '3W'' possibly a misprint for '3½"'

Printed product names: WINDOWS Magazine Presents: Access from the Ground Up · Advanced PageMaker 4.0 for Windows · DESQview: Everything You Need to Know · DOS 6: Everything You Need to Know · WINDOWS Magazine Presents. Encyclopedia for Windows · Excel 4 for Windows: Everything You Need to Know · Excel 4 for Windows: The Visual Learning Guide · WINDOWS Magazine Presents. Freelance Graphics for Windows: The Art of Presentation · Harvard Graphics for Windows: The Art of Presentation · LotusWorks 3: Everything You Need to Know · Microsoft Works for Windows By Example · NetWare 3.x: A Do-It-Yourself Guide · Novell NetWare Lite: Simplified Network Solutions · PageMaker 4.0 for Windows: Everything You Need to Know · PageMaker 4.2 for the Mac: Everything You Need to Know · PageMaker 5 for Windows: Everything You Need to Know · WINDOWS Magazine Presents. The Power of Windows and DOS Together, 2nd Edition · Quattro Pro 4: Everything You Need to Know · QuickTime: Making Movies with Your Macintosh · Smalltalk Programming for Windows (with 3¥2" disk) · Superbase Revealed! · SuperPaint 3: Everything You Need to Know · Windows 3.1: The Visual Learning Guide · Word for Windows 2: The Visual Learning Guide · Word for Windows 2 Desktop Publishing By Example · WordPerfect 5.1 for Windows Desktop Publishing By Example · WordPerfect 6 for DOS: The Visual Learning Guide · CorelDRAW! 4 Revealed! · Improv 2.1 Revealed! (with 3W' disk)

Languages: English

[Original PDF page 4](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=4)

### PDF page 5

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-807c3b68b86c4f8702800dcc8774d316d6eed65c5f7571e7f8fefb4440fa93a9)

Transcribed text:

T   ink
THINK
Dan Parks   Sydow
I ) Prima   Publishing
P.O.   Box   I   260BK
Rocklin, CA   95667-1260
(9   I   6) 786-04   26

Reading notes: Text appears fragmented with spacing artifacts (e.g., 'T   ink', 'Dan Parks   Sydow'), possibly from OCR. Possible damage in the address and phone number lines ('I ) Prima', 'I   260BK', '(9   I   6)').

Languages: English

[Original PDF page 5](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=5)

### PDF page 6

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-ee550e3fd0470e5aec3d9d8e892b69b9481211c55e0e7613f187e79059e32309)

Transcribed text:

Prima   Computer Books is an imprint of   Prima   Publishing, Rocklin, California 95677
© 1993 by Dan   Parks   Sydow. All rights reserved. No part of this book may be reproduced
or transmitted in any form or by any means, electronic or mechanical, including photo-
copying, recording, or by any information storage or retrieval system without written per-
mission from   Prima   Publishing, except for the inclusion of quotations in a review.
Executive Editor: Roger Stewart
Managing Editor: Neweleen A. Trebnik
Project   Editor: Stefan Griinwedel
Production Coordinator: Linda Beatty
Copyeditor: Betsy Ahl
Technical Reviewer: David Holzgang
Production:   Susan   Glinert, BookMakers
Proofreader: Betsy Ahl
Indexer: Dan   Parks   Sydow
Book Designer:   Susan   Glinert, BookMakers
Cover Designer:   Page   Design, Inc.
THINK C is a trademark of Symantec Corporation.   If   you have problems with THINK C
(not   the enclosed Simulator C software tutorial), notify Symantec Corporation at (617) 275-
4800.   Prima   Publishing cannot provide software support for THINK   C.   See   the warranty at
the back of the book for information about the enclosed Simulator C software tutorial.
Prima   Publishing and the author have attempted throughout this book to distinguish pro-
prietary trademarks from descriptive terms by following the capitalization style used by the
manufacturer.
Information contained in this book has been obtained by   Prima   Publishing from sources
believed to be reliable. However, because of the possibility of human or mechanical error by
our sources,   Prima   Publishing, or others, the   Publisher   does not guarantee the accuracy, ade-
quacy, or completeness of any information and is not responsible for any errors or omissions
or the results obtained from use of such information.
Library of Congress Card Number: 93-085335
Printed   in the United States of   America
93 94 95 96 RRD   10   9 8 7 6 5 4 3 2 1

Reading notes: Spaced-out letters in some words (e.g., 'Prima', 'Griinwedel') may reflect OCR spacing artifacts Telephone number (617) 275-4800 and card number 93-085335 may be affected by line-break hyphenation

Printed product names: THINK C · Simulator C

Printed dates: 1993 · 93-085335 · 93 94 95 96

Languages: English

[Original PDF page 6](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=6)

### PDF page 7

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-64c6c0c1d84f974c7d835fa3b3281d435f5f945fb478e31f21c7a579bd92b055)

Transcribed text:

To my wife, Nadine

Image description: A dedication page with a dark gradient square at upper left, five diagonal gradient bars rising to the upper right, and the bold sans-serif headline above a horizontal gradient rule, with a faint ghosted table of contents behind the page.

Reading notes: Faint ghosted text behind the page (apparently a table of contents with page numbers and titles) is too washed out to transcribe reliably and was excluded. Background ghost text is not treated as part of the transcript.

Languages: English

[Original PDF page 7](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=7)

### PDF page 8

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-3ae472dd8e54b073b32b690370f517045c99dbaea4faa5f6ec36bdd56014aa36)

Contents at a Glance

Transcribed text:

Contents   at a   Glance
Acknowledgments   xv
Introduction   xvii
Introduction to C
2   Introduction to Macintosh Programming   21
3   C Data Types   31
4   Introduction to Functions   49
5   C Operators   73
6   Decision Making: Looping   87
7   Decision Making: Branching   107
8   All   About Functions   125
9   Memory and Pointers   139
10   Arrays and Structures   161
11   Introduction to QuickDraw   187
12   Deeper into QuickDraw   205
13   Resources and ResEdit   229
14   Events   241
15   Menus   273
16   Windows   299
17   Dialog   Boxes and   Alerts   321
18   Complete   Resources-ShapeMaker   365
19   Complete   Source Code-ShapeMaker   387
20   One   for the Road-MacCertificate   413
Appendix-   ASCII   Character Codes   459
vi

Languages: English

[Original PDF page 8](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=8)

### PDF page 9

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-547b4909901160039cabddc914df7ac4df5eb6e1bcaa43ecfa312fe360c774df)

Transcribed text:

Table   of Contents
Acknowledgments
lntrod"9ction
Chapter   I   Introduction   to C
C:   What and Why   2
What   Is   C?   2
Why   Use   C on the Macintosh?   2
The Science of Programming   3
Programming C in   Six   Phases   3
The   Cycle   of Programming   7
But   I'm   Only   a Beginner!   7
A Comparison of   ANSI   C   and Macintosh   C   9
ANSI   C   9
Macintosh C   9
Ready for Some   C?   I   0
Stepping through the Code   I   I
Components of a   C   Program   17
Program Debugging   18
Syntax   Errors   18
Semantic   Errors   19
Chapter   Summary   19
xv
xvii
vii

Reading notes: OCR-like damage in 'lntrod"9ction' and 'Introduction' spacing in the table of contents Chapter page numbers appear as 'I I' and 'I 0' with uncertain reading

Languages: English

[Original PDF page 9](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=9)

### PDF page 10

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-0cad9b6963e3771d9ae0a18bf08d78d413a3870d07025ded1031c883d85c47fc)

THINK C Programming

Transcribed text:

viii   Think   THINK   C   Programming
Chapter 2   Introduction   to Macintosh Programming
Why the Mac   Is   Unique   22
The Macintosh Toolbox   22
Resources   23
The Structure of a Macintosh   Program   24
This Book's Approach to   Programming   2S
One   Step   at a Time   26
The Role of the Simulator Software   27
Using   Pseudo Code   27
Programming   with   THINK   C   29
Chapter   Summary   29
Chapter 3   C Data Types
ANSI   C   Data   32
Data Types in Action   33
What's New   33
Variables   and   Constants   3S
Why Different Data Types?   36
C   Data Types   37
The int Type   37
The long Type   39
The char Type   39
The float Type   41
Type   Conversion   42
Symbolic   Constants:   #define   44
Chapter   Summary   46
Chapter 4   Introduction   to Functions
Flashback:   What a Function   Is   SO
Calling   All   Functions   SO
Toolbox   Functions   S4
More Than just DrawStringQ   55
Function Naming   56
Advantages of Functions   S7
Reusability   58
Clarity   59
An Aid in Planning   61
Debugging   61
Program Maintainability   61
The Scope of a   Variable   62
Local Variables   62
Global Variables   64
Variable Naming   65
Value   Retention   65
Local versus Global   66
Cheating   at Windows   68
One   More Function of   Our   Own   69
Chapter   Summary   71
21
31
49

Reading notes: Some characters in the table of contents appear as 'S' in place of digits (e.g., 'S0', 'S4', '2S'), likely OCR errors.

Printed product names: THINK C

Languages: English

[Original PDF page 10](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=10)

### PDF page 11

[Cite this scan](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/1#scan-d99d2646e7dc1eaca245d3409115effbccc107c62180e7c450d4253d4554ebbb)

Chapter 5 C Operators

Transcribed text:

Chapter 5   C Operators
Operators in Action   73
The Basic Operators   75
The Assignment Operator   75
The Math Operators   76
The   Sign   Operators   78
One   Up,   One   Down   78
The   Increment   and Decrement Operators   79
But Are They Necessary?   80
Mathematical   Precedence   80
Expressions   82
Statements   83
Chapter   Summary   84
Chapter 6   Decision Making: Looping
A Sample Loop   87
Initialization   88
A Function   Call   89
The   while   Loop   89
The Loop   Block   89
Outside   the Loop   Block   90
TRUE and FALSE   90
Comparative   Operators   91
The Comparative Operators   93
The   Equality   and   Inequality   Operators   94
Comparative Operators-Not Just for   Integers   96
Assignment Operators   97
The while Loop   97
The   while   Expression   98
The   while   Body   98
Pre-execution Check   98
The for Loop   I 00
Pre-execution Check   I 02
The do-while Loop   I 03
Post-execution Check   I 03
When   "do"   You   Use   "while,''   and What   "for"?   I   04
Chapter   Summary   I   06
Chapter 7   Decision Making: Branching
The if Statement   I   07
About Branching Statements   I 08
The if   Statement-Formalized   I 09
The if-else Statement: Adding   Power   11   0
The else-if Statement:   Still   More   Power   112
The switch Statement   I   16
Logical Operators   119
switch or   if?   121
Chapter   Summary   123
Table of   Contents   ix
73
87
107

Reading notes: Table of contents page numbers in the source are partly garbled (e.g., "I 00", "I 02", "I   04"), likely OCR artifacts for 100, 102, 104.

Languages: English

[Original PDF page 11](https://www.vintageapple.net/files/7a21e7c52848fd0c3ac4cce4681acfa8ed55a37f48fd7f2da3532970cc0c916f/Think_C_Proramming_Fundamentals_For_The_Macintosh_1993.pdf#page=11)

[Next transcribed scans](https://www.vintageapple.net/transcripts/media/va-think-c-proramming-fundamentals-for-the-macintosh-1993-bd7db2/2.md)
