Anda di halaman 1dari 15

Section 2 1.

In Alice, objects inherit the characteristics of their: (1) Points


Code Project Class (*) Program Correct Correct 2. In Alice, if a procedure is de
clared for MyClownFish, which classes can us e the procedure? Mark for Review (1
) Points MyClownFish class and MySwimmer class MyClownFish class (*) MyPajamaFis
h class, MyClownFish class, and MySwimmer class Any class with "Fish" in the cla
ss name Incorrect Incorrect. Refer to Section 2 Lesson 4. 3. In Alice, new proce
dures that are declared for an instance appear in the p rocedures tab in the met
hods panel. True or false? Mark for Review (1) Points True (*) False Correct Cor
rect 4. In Alice, which of the following programming statements moves the fish f
or ward, the distance to the rock, minus the depth of the rock? Mark for Review
(1) Points this.Fish move forward {this.Rock getDistanceTo this.Fish - this.Fish
getDep th} this.Fish move forward {this.Fish getDistanceTo this.Rock - this.Roc
k getDep th} (*) this.Fish move forward {this.Rock getDistanceTo this.Fish - thi
s.Fish - 2} this.Rock move forward {this.Rock getDistanceTo this.Fish - this.Fis
h - 2} Mark for Review

Correct Correct 5. From your Alice lessons, at what point in the animation proce
ss do you con firm the items on the "Checklist for Animation Completion"? Mark f
or Review (1) Points At the end of the animation process. (*) During the animati
on process. At the beginning of the animation process. After adding each procedu
re to the code editor. Incorrect Incorrect. Refer to Section 2 Lesson 8. Section
2 6. From your Alice lessons, variables are fixed and cannot be changed. True o
r false? Mark for Review (1) Points True False (*) Correct Correct 7. From your
Alice lessons, you can run the animation to test that it works p roperly. True
or false? Mark for Review (1) Points True (*) False Correct Correct 8. Main is a
n example of what in the following code? public static void main (String[] args)
{ System.out.println{"Hello World!"); } Mark for Review (1) Points An instance
A method (*) A class A variable Correct Correct

9. What do lines 7, 10 and 13 do in the following code? Mark for Review (1) Poin
ts Export files called A, B, and num3. Create a single file containing A, B, and
the value of num3. Print "A", "B" and the value of num3 on the screen. (*) None
of the above. Correct Correct 10. A loop can be infinite (continue forever) or
conditional (stops upon a co ndition). True or false? Mark for Review (1) Points
True (*) False Correct Correct
Previous Page 2 of 10 Next Summary Section 2 11. In Alice, we use the While cont
rol statement to implement the conditional loop. True or false? Mark for Review
(1) Points True (*) False Correct Correct 12. From your Alice lessons, the If co
ntrol structure can process one true an d one false response. True or false? Mar
k for Review (1) Points True (*) False Correct Correct

13. In the Alice scene editor, where are the procedures located to precisely pos
ition an object? Mark for Review (1) Points Right click on the object, then sele
ct Procedures. (*) Right click on the object, then select Remove. In the gallery
of classes. In the package located in the gallery. Correct Correct 14. From you
r Alice lessons, saving multiple versions of an Alice animation s cene is unimpo
rtant, because it does not save time. It actually wastes time. Tru e or false? M
ark for Review (1) Points True False (*) Correct Correct 15. Which of the follow
ing are steps to use "drag-and-drop" positioning to po sition an Alice object in
a scene? Mark for Review (1) Points Select the object with your cursor. Using y
our cursor, position the object in the scene. Select a handle style. All of the
above (*) Correct Correct Section 2 16. In Java, which symbol is used to assign
one value to another? Review (1) Points < > = (*) // Mark for

Correct Correct 17. Which of the following is not a valid arithmetic operator in
Java? for Review (1) Points + / * % $ (*) Correct Correct 18. In Alice, the veh
icle property will associate one object to another. True or false? Mark for Revi
ew (1) Points True (*) False Correct Correct 19. From your Alice lessons, where
should comments be placed? ew (1) Points Above each set of programming statement
s. (*) At the end of the program. In the scene editor. In their own procedure. C
orrect Correct 20. In Alice, the procedures' arguments allow the programmer to a
djust the ob ject, motion, distance amount, and time duration. True or false? Ma
rk for Revi ew (1) Points True (*) False Mark for Revi Mark

Correct Correct Section 2 21. In Alice, functions are dragged into the control s
tatement, not the proce dure. True or false? Mark for Review (1) Points True Fal
se (*) Correct Correct 22. The Alice code editor contains the tools you need to
set up the backgroun d template and objects in the scene. True or false? Mark fo
r Review (1) Points True False (*) Incorrect Incorrect. Refer to Section 2 Lesso
n 3. 23. In Alice, which of the following procedures play a sound? ew (1) Points
playSound playAudio (*) playSoundFile playFile Correct Correct 24. In Alice, wh
ich of the following procedures resize a whole object? for Review (1) Points cla
ss_resize resizeHeight resize (*) resizeWidth Incorrect Incorrect. Refer to Sect
ion 2 Lesson 3. Mark Mark for Revi

25. From your Alice lessons, an algorithm that is done in order is in what ty pe
of order? Mark for Review (1) Points Logical Sequential (*) Simultaneous Confli
cting Correct Correct Section 3 26. Use your Greenfoot knowldege: Abstraction oc
curs in many different ways i n programming. True or false? Mark for Review (1)
Points True (*) False Correct Correct 27. From your Greenfoot lessons, which of
the following are examples of abstr action? Mark for Review (1) Points (Choose a
ll correct answers) Playing a range of sounds when keyboard keys are pressed. (*
) A single instance displays a single image. Assigning a different keyboard key
to each instance. (*) Programming a single movement for a single instance. Assig
ning a different image file to each instance. (*) Correct Correct 28. In a Green
foot loop constructor, which component is a counter that contro ls how many time
s the statement is executed? Mark for Review (1) Points Local loop While loop Lo
op variable (*)

Condition Correct Correct 29. From your Greenfoot lessons, what types of values
cannot be stored in a l ocal variable? Mark for Review (1) Points Class name Obj
ects Integers World name method (*) Incorrect Incorrect. Refer to Section 3 Less
on 10. 30. From your Greenfoot lessons, when do infinite loops occur? iew (1) Po
ints When the loop is executed. Only in while loops. When the end to the code is
n't established. (*) When the end to the act method isn't established. Incorrect
Incorrect. Refer to Section 3 Lesson 10. Section 3 31. Which of the following t
ype of audience should you ask to play your Green foot game during the testing p
hase? Mark for Review (1) Points Testing Target (*) Primary Programmer Incorrect
Incorrect. Refer to Section 3 Lesson 4. 32. In Greenfoot, the image below is an
example of what construct? Mark for Rev

Mark for Review (1) Points Method Comment Constructor (*) Class Incorrect Incorr
ect. Refer to Section 3 Lesson 12. 33. The image below is an example of what Gre
enfoot construct? Mark for Review (1) Points Method (*) Constructor Conditional
Class Correct Correct 34. Which class holds the method that ends a Greenfoot gam
e? w (1) Points Greenfoot (*) Class GreenfootImage Actor Correct Correct 35. In
Greenfoot, an if-statement is used to alternate between displaying two images in
an instance. True or false? Mark for Review (1) Points True False (*) Correct C
orrect Mark for Revie

Section 3 36. Using Greenfoot, how do we change the size and resolution of the W
orld in stance? Mark for Review (1) Points Edit the methods in the class. Edit t
he values in the constructor. (*) Delete the instance. Edit the values in the cl
ass's act method. Incorrect Incorrect. Refer to Section 3 Lesson 8. 37. In Green
foot, defined methods must be used immediately. True or false? Mark for Review (
1) Points True False (*) Correct Correct 38. From your Greenfoot lessons, how do
you call a defined method? Review (1) Points Call the method from the act metho
d. (*) Call the method from the defined method. Write the method in the World su
perclass. Write the method in the instance. Write the method in the source code.
Correct Correct 39. Use your Greenfoot knowledge to answer the question. One re
ason to write a defined method in a class is to change the behavior of the class
. True or fals e? Mark for Review (1) Points True (*) False Correct Correct Mark
for

40. What type of Greenfoot method would be used to turn an object? Review (1) Po
ints orientTo( ); turnAround( ); move ( ); turn( ); (*) Correct Correct Section
3
Mark for
41. In the Greenfoot IDE, which of the following are components of a paramete r?
Mark for Review (1) Points (Choose all correct answers) Parameter type (*) Para
meter return Parameter name (*) Parameter method Parameter void Correct Correct
42. From your Greenfoot lessons, when a method needs additional data to perfo rm
a task, this data comes from parameters. True or false? Mark for Review (1) Poi
nts True (*) False Correct Correct 43. From your Greenfoot lessons, to create a
new instance of the Duke class, you right-click on the class, then select which
of the following commands in the class menu? Mark for Review (1) Points New subc
lass... Set image...

new Duke() (*) Inspect Remove Correct Correct 44. In Greenfoot, which of the fol
lowing are execution controls? eview (1) Points (Choose all correct answers) Run
(*) Act (*) Speed (*) Move Turn Correct Correct 45. From your Greenfoot lessons
, which of the following methods return the cu rrent rotation of the object? Mar
k for Review (1) Points World getClass() World getWorld() int getRotation() (*)
getXY() Correct Correct Section 3 46. What type of parameter does the Greenfoot
playSound method expect? for Review (1) Points name of a sound file (as String)
(*) name of an integer (as int) name of a keyboard key (as String) name of the c
lass (as String) Mark Mark for R

Correct Correct 47. From your Greenfoot lessons, the keyDown method is located i
n which class ? Mark for Review (1) Points Actor Greenfoot (*) GreenfootImage Wo
rld Correct Correct 48. From your Greenfoot lessons, what can methods belong to?
w (1) Points (Choose all correct answers) Galleries Classes (*) Scenarios Objec
ts (*) All of the above Incorrect Incorrect. Refer to Section 3 Lesson 5. 49. In
Greenfoot, you can use comparison operators to compare a variable to a random n
umber. True or false? Mark for Review (1) Points True (*) False Correct Correct
50. From your Greenfoot lessons, which axes define an object's position in a wor
ld? Mark for Review (1) Points (Choose all correct answers) x (*) Mark for Revie

z y (*) w Correct Correct

Anda mungkin juga menyukai