Unit 9 Animation and Games in Javascript (CodeHS)

Unit 9 Animation and Games in Javascript (CodeHS)

Assessment

Flashcard

Computers

10th Grade

Hard

Created by

Quizizz Content

FREE Resource

Student preview

quiz-placeholder

24 questions

Show all answers

1.

FLASHCARD QUESTION

Front

Which of the following statements are true about the code in the image: I. ball is a local variable II. the ball variable in draw is different from the ball variable in main III. ball is a global variable IV. ball’s scope includes both main and draw

Back

III. and IV.

2.

FLASHCARD QUESTION

Front

The following program animates a ball using a timer. We want the animation to stop when the user clicks the mouse. Which statement would stop the animation in this program?

Back

Media Image

3.

FLASHCARD QUESTION

Front

What goes in the blank?

Back

Media Image

4.

FLASHCARD QUESTION

Front

Which of the following Does Not make code more reusable?
- Using const variables instead of hard-coded values
- Using specific values in functions instead of using parameters
- Writing multiple functions that solve small subproblems rather than one function which solves the entire problem
- Using parameters to generalize functions

Back

Using specific values in functions instead of using parameters

5.

FLASHCARD QUESTION

Front

Which function is more reusable?

Back

Media Image

6.

FLASHCARD QUESTION

Front

Imagine you are filling a 100 by 100 canvas with circles. They are touching but not overlapping at four points. Their radius is 10. How many circles will fit on the canvas?

Back

25

7.

FLASHCARD QUESTION

Front

What statement would you use to determine if ball is hitting the right edge of the window?

Back

Media Image

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?