This website is preserved for historical and scholarly reference and is no longer actively maintained.
QUIZ 13
September 19, 1997
#1. In execution of the code segment below, if x is initially 3 and y is initially 5, what will be the final value of s? ______ (2 pts.)
s = 0;
if ( x > 0 ) s++;
else if ( y > 0 ) s++;
#2. Draw a flowchart (graphic illustration) for the following code segment. (4 pts.)
if ( x >= 0 )
{
}
else
{
}
#3. Draw a flowchart (graphic illustration) for the following code segment. (4 pts.)
if ( numGrade >= 90 )
{
}
else if (numGrade >= 70)
{
}
else
{
}