Course Notes for Computer Science 430
C and UNIX
Spring 1997
Tim Wahls
office: E-258K Olmsted
phone: 948-6085
email: wahls@psu.edu
Sample student programs are now available! See the directory:
~taw2/pub/student or the link at section VII of this page
Final Exam
- Monday, May 5 from 6:00 to 8:30
- 150 points
- about 50 points comprehensive
- about 100 points on material since the midterm
- open book and notes
- note the links to old exams at the bottom of this page
- Course Syllabus
- Course Policies
-
UNIX and C resources page created by Dr. Bui
- Frequently
Asked Questions page for the Sun Cluster
-
FTP and Telnet Software for Windows 95
- Assignments
- Assignment 1
- Program 1
- Program 2
- Program 3
- Program 4
- Program 5
- Program 6 (extra credit added 3/19/97)
- Extra Credit Assignment
- Program 7
- Program 8
- Program 9
- Example Student Programs
- Introduction to UNIX
- UNIX Basics
- Creating and Editing Files
with vi
- Basic UNIX Commands
- The UNIX File System
- Protection Modes
- C Basics
- Compiling C Programs
- General Structure of
a C Program
- Comments in C
- Variable Declarations
- Types for Variables
- Assignment Statements
- Constants
- Arithmetic
Operators and Expressions
- Type Casting
-
Precedence and Grouping
- Shortcut Operators
- Using Electronic Mail
- Flow of Control
- Boolean Expressions
and Operators
- Relational
(Comparison) Operators
- Boolean Operators and Compound
Boolean Expressions
- if Statements
- if Expressions
- switch Statements
- for Loops
- while Loops
- do while Loops
- Using break and exit()
- Functions
- Function Calls
- Standard (Built-in)
Functions
- User Defined Functions
- Program Format
- Pass-by-Value
Parameters
- Pass-by-Address
Parameters
- The return Statement
- Scoping Rules
- UNIX Commands
- File Information
- Other Information
- Input/Output
- Using printf()
- Using scanf()
- Text Files
- Reading and Writing
Text Files
- Standard Files
- File Processing
- UNIX Input and Output
- Arrays
- One-Dimensional Arrays
- Multidimensional
Arrays
- Declaring New Types
- Initializing Arrays
- Advice on Using Arrays
- Strings
- Structures
- Structs and Functions
- Nested Structs
- Other Declaration
Methods
- Dynamic Memory Management
- Allocating Memory
- Sizing Arrays at Runtime
- Linked Lists
Exams from Spring 1996:
Exams from Fall 1996:
Current Exams:
And some fun: a link to a
Top
Ten list of reasons for learning UNIX and C.
Disclaimer