Lecture 16: Functions 2
Tuesday, October 25, 2011 Status: complete[

Powerpoint Slides: L16Functions2.ppt (Park)
Reading Assigned: 6.3-6.4
Homework Due: Homework 7
Homework Assigned: Homework 8
Topics Covered:
- Local variables & scope
- Local variables vs global variables
Programs Shown:
- Local variables have their own storage: local1.c.txt
- Local variables names: local2.c.txt
- Local vs global variables: local3.c.txt
-
Uninitialized local variables have garbage value:
garbage1.c.txt
and
garbage2.c.txt.
THESE TWO PROGRAMS DEMONSTRATE A VERY BAD BUG. DO NOT COPY.