EE 102 Sample Programs for D'Orazio textbook
-
First programs
-
data types and arithmetic operations
-
Examples how to format printouts for floating point numbers
-
Basic Input and Output
-
Selection with if, alternative selections with if else, and switch case
-
Repetition stgatements - loop
- How to quit/end the while loop - do the same thing in seven different ways
Yet it is possible to do it in more ways than that - will look at it later
- Data from files, use of break and continue
- More applications for loops
- Use of switch case inside loops
- do while loops, discussion on loop exit conditions
- for loops
-
Functions
- Introduction
- More about functions
- Passing variables by reference
- Variable scope
- Recursive functions
- Outline of advanced features
-
Introduction to Arrays, One-dimensional arrays
- The step by step introduction - compare the group of programs (may be too slow for impatient readers)
- 1D array examples
-
Two-dimensional arrays
-
Introduction to Pointers
-
C-style Strings
-
Files and character arrays
- Reading from a text file
- More file processing, writing to a text file
- Processing numerical data from a text file
Source code listings were prepared using Code2HTML, courtesy of Peter Palfrader.