CPS 1 - Spring, 1997 - Ramm 2/17/97 #14
Chapter 3. Numerical Computation and a Study of Functions
- Real Example: Loan Payout Program
payout.pas
- Some Theoretical Concepts
- Putting things in a row (countable sets)
- Sets mapping integers to integers uncountable
- Same as proof that irrational numbers are uncountable
- Back to Arrays
- Simple Statistics Example
- Write in class
- Read in data
- Print out
- Use two loops
- Note:
- Size of Array (bigger than needed)
- Keeping track of actual amount of data
- Using a Sentinel for loop control
inout.pas
- Do More:
- Print out in reverse order
- Statistics: Mean, Max, and Min
- Counting and Summing select items in a list
inout2.pas
- Motivate Subroutines/Procedures