Learn to Program using Alice

Practice Test for the Lesson Titled

Setting the Stage Manually, Part 2

Published:  May 1, 2007
Last updated:  June 5, 2007
By Richard G. Baldwin

File: Alice0120PracticeTest.htm


Questions

1.  True or False:  Every Alice object has, or at least can have:

Answer and Explanation

2.  True or False:  The current properties, methods, and functions belonging to an object can be exposed by:

Answer and Explanation

3.  True or False:  A property is a value stored in an object that specifies the real estate owned by the object.

Answer and Explanation

4.  True or False:  A method is a set of instructions, grouped together in a special way and given a name as a group.  The instructions in the method can be executed by the object to cause it to do something that it is asked to do.

Answer and Explanation

5.  True or False:  Every object has a group of built-in methods, commonly referred to in Alice literature as primitive methods.  Some objects also have special methods in addition to the primitive methods that are often called custom methods.  In addition to those methods, you can create your own methods by clicking a button that reads create new method.

Answer and Explanation

6.  True or False:  In all cases, the names of the primitive methods will tell you exactly what will happen when the method is called on an object.

Answer and Explanation

7.  True or False:  Even if the name of a primitive method doesn't adequately describe its purpose and behavior, in most cases you can call the method interactively on a specific object and observe its behavior on the screen.  Custom methods and methods that you create can also be called interactively.

Answer and Explanation

8.  True or False:  A function is a set of instructions, grouped together in a special way and given a name as a group.

Answer and Explanation

9.  True or False:  According to the Alice terminology, a function causes an object to perform an action such as to move in a prescribed direction for a specified distance.  A method returns a value, such as the width of the object to which the method belongs.

Answer and Explanation

10.  True or False:  You can call methods interactively to manipulate objects as an alternative to using the mouse for that purpose.

Answer and Explanation

11.  True or False:  You can write the code to cause an object's methods to execute in sequential order, or you can write code to cause them to execute concurrently.  You can write code to cause them to execute repeatedly, and you can write code to cause the methods that are selected for execution to depend on some other circumstance (selection).

Answer and Explanation

12.  True or False:  It is possible to call an object's methods interactively, one at a time, during the development process.  This provides at least the following two benefits:

  1. The ability to set the stage in a manner that is somewhat more precise than just dragging objects around with the mouse.
  2. The ability to create short animation sequences and manually execute them one step at a time to see if they do what you want them to do before you write the steps into your animation program.

Answer and Explanation

13.  True or False:  People who write programs that manipulate objects in 3D space think in terms of a 3D coordinate system where a specific point or location in that coordinate system is specified by four coordinate values.

Answer and Explanation

14.  True or False:  Directions in Alice are typically referred to as UNDER, OVER, RIGHT, LEFT, UP, and DOWN, rather than by using the more abstract mathematical concepts that are common in other 3D programming environments.

Answer and Explanation

15.  True or False:  The Alice terminology for the combined position and orientation of an object is viewpoint or more correctly pointOfView.

Answer and Explanation

16True or False:  Many programs need to establish an absolute viewpoint or pointOfView for every object in the world when the program starts running.

Answer and Explanation

17True or False:  Most objects in an Alice world have a center point but a few objects such as objects of the Penguin class and the Coach class don't have a center point.  They have a set of orthogonal axes instead.

Answer and Explanation

18True or False:  When you create a new world by selecting a ground template from the welcome screen and then use the long approach to add an object to the world, the center points for the world object, the ground object, and the object from the gallery will all be aligned.

Answer and Explanation

19True or False:  Depending on how you set your preferences, you can cause various types of information to be displayed in any one of four different formats in Alice.

Answer and Explanation

20True or False:  Just like in real life, it is physically impossible for two objects, such as an ice skater and a parking meter to occupy exactly the same space in Alice.

Answer and Explanation

21True or False:  Sometimes when you need to enter a numeric value, the value that you need to enter won't appear on the menu.  In this case, you can select other from the menu.  This will cause a numeric keypad to appear on your screen.  You can use your mouse to enter the numeric value and click the Okay button.

Answer and Explanation

22True or False:  The menus that are used to construct rotation parameters in Alice are given in degrees.

Answer and Explanation

23True or False:  While it is possible to interactively call methods on any object that you create from the classes in the gallery, it is not possible to interactively call methods on the camera, the light, or the ground.

Answer and Explanation

24True or False:  You can interactively make the following method calls to relocate the camera to a position that is ten meters away from the center point of the ground, located 1.5 meters above the ground, and oriented toward the northwest (where the blue axis belonging to the ground points to the south).

  1. camera.setPointOfView(...)\ground
  2. camera.turn(...)\RIGHT\135
  3. camera.moveAwayFrom(...)\ground\10
  4. camera.move(...)\UP\1.5

Answer and Explanation

25True or False:  To rotate an object around its red axis, (often referred to as yaw), call the turn method and specify either LEFT or RIGHT as a parameter.

Answer and Explanation

26True or False:  To rotate an object around its red axis, (often referred to as pitch), call the turn method and specify either FORWARD or BACKWARD as a parameter.

Answer and Explanation

27True or False:  To rotate an object around its blue axis, (often referred to as roll), call the roll method and specify either LEFT or RIGHT as a parameter.

Answer and Explanation

28True or False:  To rotate an object around its green axis, (often referred to as yaw), call the turn method and specify either LEFT or RIGHT as a parameter.

Answer and Explanation

29True or False:  For the case where you can see any two of the three axes, but you can't see the third axis, you can always figure out what the direction of the missing third axis is.

Answer and Explanation

30True or False:  When you rotate an object around one of its axes, one of the three axes will end up pointing in a different direction and the other two axes will continue pointing in the same direction as before..

Answer and Explanation

 



Copyright 2007, Richard G. Baldwin.  Faculty and staff of public and private non-profit educational institutions are granted a license to reproduce and to use this material for purposes consistent with the teaching process.  This license does not extend to commercial ventures.  Otherwise, reproduction in whole or in part in any form or medium without express written permission from Richard Baldwin is prohibited.


The following image is the splash screen from Alice 2.0, and is the property of the developers of Alice at Carnegie Mellon.

Answers and Explanations


Answer 30

False

Explanation 30

Back to Question 30
 


Answer 29

True

Explanation 29

Back to Question 29
 


Answer 28

True

Explanation 28

Back to Question 28
 


Answer 27

True

Explanation 27

Back to Question 27
 


Answer 26

True

Explanation 26

Back to Question 26
 


Answer 25

False

Explanation 25

Back to Question 25
 


Answer 24

False - must deal with rotation in revolution instead of degrees alone.

Explanation 24

Back to Question 24
 


Answer 23

False

Explanation 23

Back to Question 23
 


Answer 22

False

Explanation 22

Back to Question 22
 


Answer 21

True

Explanation 21

Back to Question 21
 


Answer 20

False

Explanation 20

Back to Question 20
 


Answer 19

False

Explanation 19

Back to Question 19


Answer 18

False

Explanation 18

Back to Question 18


Answer 17

False

Explanation 17

Back to Question 17


Answer 16

True

Explanation 16

Back to Question 16


Answer 15

True

Explanation 15

Back to Question 15


Answer 14

False

Explanation 14

Back to Question 14


Answer 13

False

Explanation 13

Back to Question 13


Answer 12

True

Explanation 12

Back to Question 12


Answer 11

True

Explanation 11

Back to Question 11


Answer 10

True

Explanation 10

Back to Question 10


Answer 9

False

Explanation 9

Back to Question 9


Answer 8

True

Explanation 8

Back to Question 8


Answer 7

False

Explanation 7

Back to Question 7


Answer 6

False

Explanation 6

Back to Question 6


Answer 5

True

Explanation 5

Back to Question 5


Answer 4

True

Explanation 4

Back to Question 4


Answer 3

False

Explanation 3

Back to Question 3


 

Answer 2

True

Explanation 2

Back to Question 2


Answer 1

False

Explanation 1

Back to Question 1


Copyright 2007, Richard G. Baldwin.  Faculty and staff of public and private non-profit educational institutions are granted a license to reproduce and to use this material for purposes consistent with the teaching process.  This license does not extend to commercial ventures.  Otherwise, reproduction in whole or in part in any form or medium without express written permission from Richard Baldwin is prohibited.

The following image is the splash screen from Alice 2.0, and is the property of the developers of Alice at Carnegie Mellon.

-end-