7. (TCO 4) The following C# code _____ compile; however, it contains a _____ err
ID: 3771994 • Letter: 7
Question
7. (TCO 4) The following C# code _____ compile; however, it contains a _____ error.
int x = 15, y = 10;
if (x < y);
Console.WriteLine("x is less than y");
(Points : 5) will, compiler
will, logical
will not, compiler
will not, logical
if (b <= c && d >= e)
double sum = 0, height = 2.0, stop =10, max = 50;
int track = 0, num = 0;
while (num <= stop)
{
sum = sum + height * num;
if (sum <= max)
track++;
num++;
}
int i = 1, j = 1;
for (i = 1; i < 4; i++)
{
for (j = 1; j < 4; j++)
{
Console.Write("{0}{1} ", i, j);
}
}
three
four
nine
16
if (b <= c && d >= e)
(Points : 5) b <= cc || d
d >= e
if()
Explanation / Answer
.7. b) will , logical // the write line is execute always as the if statement ended just after the if unsually without any statent.
8. a)b <= c
9. c)track, sum
10. a)three
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.