Programming Flashcard

Programming Flashcard

Assessment

Flashcard

Computers

11th Grade

Hard

Created by

Wayground Content

FREE Resource

Student preview

quiz-placeholder

18 questions

Show all answers

1.

FLASHCARD QUESTION

Front

What value would be returned for findTheMiddle(2110890125)? Options: 8, The code will error, 9, 89

Back

89

2.

FLASHCARD QUESTION

Front

Which expression is true? Options: true && !true, !false || !true, true && false, false || false || !true

Back

!false || !true

3.

FLASHCARD QUESTION

Front

What will this code output? Options: Hello Karel, Hello Karel Second if statement!, Second if statement!, This program will print nothing

Back

Second if statement!

4.

FLASHCARD QUESTION

Front

What will this program print if the value of grade is 80? A, B, C, Nothing

Back

C

5.

FLASHCARD QUESTION

Front

What are the final values of x and y after the code is executed?
int x = 100;
int y = 100;
if (x <= 100)
{ if (y > 100)
{
x = 200;
}
else
{
x = 99;
}
}
else{
x++;
}
y = x + y;

Back

x = 99, y = 199

6.

FLASHCARD QUESTION

Front

Which of the following test cases can be used to show that the code does NOT work as intended? Options: calculateRate(35);, calculateRate(40);, calculateRate(45);, calculateRate(55);

Back

calculateRate(40);

7.

FLASHCARD QUESTION

Front

Given a, b, and c are properly initialized boolean values, what values would make the following expression false? (a || b) || (b || c) || (!a || b);

Back

Nothing. The expression will always be true.

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?