Node:Questions for Chapter 6, Previous:Scope example, Up:Scope
gnoahs_park
that declares 4 variables. Two
global integer variables called num_gnus
and
num_gnats
, and two local floating point variables within
the function main
, called avg_gnu_mass
, and
avg_gnat_mass
. Then add another function called
calculate_park_biomass
, and pass avg_gnu_mass
and
avg_gnat_mass
to it. How many different storage spaces are used
when this program runs? (Hint: are avg_gnu_mass
and
avg_gnat_mass
and their copies the same?)