2.99 See Answer

Question: 1. Write a statement that declares a


1. Write a statement that declares a String array initialized with the following strings:
“Einsteinâ€, “Newtonâ€, “Copernicusâ€, and “Keplerâ€.
2. Write a loop that displays the contents of each element in the array that you declared in Question 3(a).
3. Write code that displays the total length of all the strings in the array that you declared in Question 3(a).


> Refer to your answer for Checkpoint14.41 . What does the method return? Data from Checkpoint 14.41: What KeyEvent method can you call to determine which key the user pressed?

> What KeyEvent method can you call to determine which key the user pressed?

> What type of event happens when the user presses and releases a key that produces a Unicode character?

> In what package is the Shape class?

> Consider the following class declaration: public class Circle { private double radius; public Circle(double r) { radius = r; } public double getArea () { return Math.PI * radius * radius; } public double getRadius() { return radius; } } 1. Write a toStri

> What type of event happens when the user releases a key on the keyboard?

> What type of event happens when the user presses a key on the keyboard?

> How do you set the size of a video’s viewing window?

> In what package are the three classes?

> What three classes do you use to play a video file?

> What does the MediaPlayer method setCycleCount do?

> What does the MediaPlayer method setAutoPlay do?

> Refer to your answer to Checkpoint14.31 . In what package are the two classes? Data from Checkpoint 14.31: What two classes do you use to play an audio file?

> What two classes do you use to play an audio file?

> If you want to combine multiple effects on a single node, which Node class method would you use to set the effect?

> The values variable references a two-dimensional double array with 10 rows and 20 columns. Write code that sums all the elements in the array and stores the sum in the variable total.

> Write assignment statements that perform the following operations with the variables a, b, and c. 1. Adds 2 to a and stores the result in b 2. Multiplies b times 4 and stores the result in a 3. Divides a by 3.14 and stores the result in b 4. Subtracts 8

> How is the screen coordinate system different from the Cartesian coordinate system?

> Which effect class do you use to create a reflection of a node?

> Which effect class do you use to create a glowing effect?

> Which effect class do you use to create an antique sepia tone effect?

> What three effect classes can you use to create blur effects?

> Which effect class do you use to adjust an image’s hue, saturation, brightness, and contrast?

> Which effect class do you use to create a shadow inside the edges of a node?

> Which effect class do you use to create a drop shadow?

> In what package are the effect classes?

> How can you change an animation’s interpolator?

> Write code that calculates the average of all the elements in the grades array that you declared in Question 6. Data from Question 6: Declare a two-dimensional int array named grades. It should have 30 rows and 10 columns.

> In what package is the Duration class?

> In a window 640 pixels wide by 480 pixels high, what are the coordinates of the pixel in the lower-right corner?

> How do you specify the amount of time that an animation should last?

> Which transition class causes a node to fade?

> Which transition class causes a node’s fill color to change?

> Which transition class causes a node’s stroke color to change?

> Which transition class causes a node to become larger or smaller?

> Which transition class causes a node to rotate?

> Which transition class causes a node to move from one position on the screen to another?

> Which of the following is not a subclass of the Shape class? 1. Circle 2. Rectangle 3. Triangle 4. Ellipse

> In a program you need to store the identification numbers of ten employees (as int values) and their weekly gross pay (as double values). 1. Define two arrays that may be used in parallel to store the 10 employee identification numbers and gross pay amou

> What shape method do you call to scale a shape along the Y axis?

> What shape method do you call to scale a shape along the X axis?

> What are the coordinates of the pixel in the upper-left corner of the window?

> When speaking of colors, what does RGB mean?

> If a style definition for a specific type of node contradicts a style rule in the .root definition, which takes precedence—the more specific style definition, or the .root definition?

> If you want to apply styles to all of the nodes in a scene, what selector would you use in a style definition?

> Assume scene is the name of a Scene object, and stylesheet.css is the name of a CSS stylesheet. Write the statement that applies the stylesheet.css stylesheet to scene.

> If you want to place a dotted border around a Label control, which CSS style property would you set?

> How do you determine the file that the user selected with either an open dialog or a save dialog?

> How do you display a save dialog?

> How do you display an open dialog?

> In what package is the FileChooser class?

> What type of event do menu items generate when selected by the user?

> What class do you use to create a check menu item? How do you cause it to be initially selected?

> How do you create a relationship between radio menu items so only one may be selected at a time?

> What class do you use to create a radio menu item? How do you cause it to be initially selected?

> If you want a control’s text to appear in bold, which CSS style property would you set?

> What class do you use to create a menu item?

> What class do you use to create a menu?

> What class do you use to create a menu bar?

> Write code that creates an ArrayList that can hold String objects. Add the names of three cars to the ArrayList, and then display the contents of the ArrayList.

> Briefly describe each of the following menu system items: 1. Menu bar 2. Menu 3. Menu item 4. Check menu item 5. Radio menu item 6. Submenu 7. Separator bar

> How do you retrieve the text that the user has typed into a TextArea control?

> What is text wrapping? What is line wrapping? How do you enable text wrapping in a TextArea control?

> What is the TextArea’s default number of rows displayed? How do you change the number of rows?

> What is the TextArea’s default number of columns displayed? How do you change the number of columns?

> What is the difference between a TextArea and a TextField?

> How do you get a Slider’s current value?

> Which CSS style property specifies the font for a control’s text?

> What type of event does a Slider generate when its slider knob is moved?

> What Slider methods do you use to perform each of these operations? 1. Establish the spacing of major tick marks. 2. Establish the spacing of minor tick marks. 3. Cause tick marks to be displayed. 4. Cause labels to be displayed.

> The variable names references an integer array with 20 elements. Write a for loop that prints each element of the array.

> What is the difference between an editable ComboBox and an uneditable ComboBox?

> What type of event do ComboBox controls generate when they are clicked?

> How do you retrieve the selected item from a ComboBox?

> In what type of object does the ComboBox control keep its list of items?

> How do you set the orientation of a ListView control?

> What is multiple interval selection mode?

> What is single selection mode?

> How do you retrieve the selected item from a ListView control?

> You haven’t yet learned about the MenuButton control, but you have learned how to convert JavaFX class names to CSS type selectors. What would the type selector name for the MenuButton class be?

> How do you set the size of a ListView?

> Consider the following class declaration: public class Square { private double sideLength; public double getArea () { return sideLength * sideLength; } public double getSideLength () { return sideLength; } } 1. Write a no-arg constructor for this class.

> What type of event do CheckBox controls generate when they are clicked?

> In code, how do you make a CheckBox appear selected?

> How do you determine in code whether a CheckBox is selected?

> What type of event do RadioButton controls generate when they are clicked?

> In code, how do you make a RadioButton appear selected?

> How do you determine in code whether a RadioButton is selected?

> How do you create a mutually exclusive relationship between RadioButton controls?

> In a style definition, what type of selector begins with a # character?

> In the hexadecimal color value #0511FF, the FF value specifies which color component?

> What is the type selector name that corresponds to each of the following JavaFX types? Button TextField Label ImageView

> Design a class named Pet, which should have the following fields: - name. The name field holds the name of a pet. - animal. The animal field holds the type of animal that a pet is. Example values are “Dogâ€, “Catâ€, and “Birdâ€. - age. The age fiel

> What type of scene graph node can have children? What type cannot?

> What are the three types of nodes in a scene graph?

> What is a scene graph?

> Is a window the same as a stage, or a scene?

> What is JavaFX?

> What is an event-driven program?

> Describe the three BorderPane constructors.

2.99

See Answer