Skip to main content\(
\newcommand{\lt}{<}
\newcommand{\gt}{>}
\newcommand{\amp}{&}
\definecolor{fillinmathshade}{gray}{0.9}
\newcommand{\fillinmath}[1]{\mathchoice{\colorbox{fillinmathshade}{$\displaystyle \phantom{\,#1\,}$}}{\colorbox{fillinmathshade}{$\textstyle \phantom{\,#1\,}$}}{\colorbox{fillinmathshade}{$\scriptstyle \phantom{\,#1\,}$}}{\colorbox{fillinmathshade}{$\scriptscriptstyle\phantom{\,#1\,}$}}}
\)
Section 11.7 Arrays-WE2-P4
Subgoals for Evaluating Arrays.
Set up array from 0 to size-1
Evaluate data type of statements against array
-
Trace statements, updating slots as you go
Remember assignment subgoals
Subsection 11.7.1
Assume the following given declarations:
Give the contents of alpha after the execution of these statements.
alpha = new int[5];
for (int i = 0; i < 5; i++)
alpha[i] = i + 1;
Exercises Exercises
1.
2.
3.
4.
5.
You have attempted
of
activities on this page.