How can the parent version of an inherited method that is overridden in a subclass be called in that subclass in C#?
A URL is a type of _________. a. Web page b. URI c. Link d. Network
How would the results of the following two statements differ?
What type of error occurs when the interpreter fails to recognize code? a. Debugging b. Syntax c. Run-time d. Logic
Which API provides access to data from a devices gyroscope and accelerometer? a. Geolocation API b. Battery Status API c. Device Orientation API d. WebRTC API
Consider the following C program: What is the value of x after the assignment statement in main, assuming a. Operands are evaluated left to right. b. Operands are evaluated right to left. int fun...
What number is displayed by this program? Set Number1 = 4 Set Number1 = Number1 + 1 Set Number2 = 3 Set Number2 = Number1 * Number2 Write Number2
The term defensive programming refers to which of the following (select all that apply): a. Ensuring that input data are in the proper range b. Ensuring that a division by 0 does not take place c....
If X = 1 and Y = 2 determine whether each of the following expressions is true or false. (a) T F X >= X OR Y >= X (b) T F X > X AND Y > X (c) T F X > Y OR X > 0 AND Y < 0 (d) T F NOT(NOT(X == 0) AND...
The number N factorial, denoted by N!, is defined to be the product of the first N positive integers: N! = 1 2 . . . N For example: 5! = 1 2 3 4 5 = 120 7! = 1 2 3 4 5 6 7 = 5,040 Find...
Give the output of the loop in Exercise 19. Data from Exercise 19 Declare K As Integer For (K = 3; K
What is the output of the code corresponding to the following pseudocode? Declare I, J As Integer For (I = 1; I
What is the output of the code corresponding to the following pseudocode? Declare HelloCount As Integer Set HelloCount = 1 Repeat Repeat Write "Hello" Until HelloCount >= 1 Set HelloCount =...
The factorial of a positive integer N, denoted by N!, is defined by the following: N! = 1 2 . . . N (Note: 0! = 1 ) Using subprograms and functions, create a recursive program to compute N!. The...
Redo Programming Challenge 6 but use a binary search. Bonus: Add pseudocode to check how many iterations must be made for each number entered by the user, and, if you also complete Programming...
Create a Visual Basic Windows application. Use the following names for the solution and project, respectively: Valley Solution and Valley Project. Save the application in the VB2015\Chap01 folder....
The Internet contains a vast amount of code snippets that you can use in your Visual Basic applications. And in many cases, you can use the snippet without fully understanding each line of its code....
Open the Debug Solution (Debug Solution.sln) file contained in the VB2015\Chap06\ Debug Solution-B15 folder. Open the Code Editor window and review the existing code. Start and then test the...
Create an application that displays a circles area and circumference, given its radius. Use the following names for the solution and project, respectively: Circle Solution and Circle Project. Save...
In this exercise, you experiment with procedure-level and class-level variables. Open the VB2015\Chap03\Scope Solution\Scope Solution (Scope Solution.sln) file. The application allows the user to...
Modify the HeapIntPriorityQueue class written in this chapter to make it configurable in ways similar to Javas PriorityQueue class. Make it possible for the heap to be a min-heap or max-heap. (If you...
Write a method called descending that accepts an array of integers and rearranges the integers in the array to be in descending order using a PriorityQueue as a helper. For example, if the array...
In this exercise, you modify the Net Income or Loss application from Lesson A. Use Windows to make a copy of the Net Solution folder. Rename the copy Net Solution- Print. Open the Net Solution (Net...
Patti Garcia owns two cars, referred to as Car 1 and Car 2. She wants to drive one of the cars to her vacation destination, but shes not sure which one (if any) would cost her the least amount in...
Explain why a class might provide a set method and a get method for an instance variable.
In this exercise, you modify the wedding reception application from Exercise 9. The modified application will display the number of rectangular tables needed to seat the bridal party as well as the...
Factorials are used frequently in probability problems. The factorial of a positive integer n (written n! and pronounced n factorial) is equal to the product of the positive integers from 1 to n....
Write a line of code that performs each of the following tasks: a) Specify that class PieceWorker inherits from class Employee. b) Call superclass Employees toString method from subclass PieceWorkers...
Modify Solution 2 shown earlier in Figure 6-4. The solution should now keep track of the number of times Sahirahs laser beam missed the spider. After saying You are safe now. The spider is dead.,...
In this exercise, you create an application that displays the name of the artist corresponding to the song title selected in a combo box. Create the application, using the following names for the...
Discuss three proper ways in which you can assign superclass and subclass references to variables of superclass and subclass types.
What value is contained in the integer variable size after the following statements are executed?
In this exercise, you learn how to specify that one or more arguments are optional in a Call statement. Open the VB2015\Chap07\Optional Solution\Optional Solution (Optional Solution.sln) file. a....
Show the contents of a queue after the following operations are performed. Assume the queue is initially empty. enqueue(45); enqueue(12); enqueue(28); dequeue(); dequeue(); enqueue(69); enqueue(27);...
Write a method called depthSum that returns the sum of the values stored in a binary tree of integers weighted by the depth of each value. The method should return the value at the root, plus 2 times...
Write a method called removeLeaves that removes the leaves from a tree. A leaf is a node that has empty left and right subtrees. If your method is called on an empty tree, the method does not change...
Write a method called matches that returns a count of the number of nodes in one tree that match nodes in another tree. A match is defined as a pair of nodes that are in the same position in the two...
Write a program that prompts the user to enter an integer between 0 and 15 and displays its corresponding hex number. For an incorrect input number, display invalid input. Here are some sample runs:...
Suppose we have a hash set that uses the standard mod hash function shown in the chapter and uses linear probing for collision resolution. The starting hash table length is 5, and the table chooses...
Write a method called kthSmallest that accepts a PriorityQueue of integers k and an integer as parameters and returns the kth-smallest integer from the priority queue. For example, if the queue...
Write a program that displays all the numbers from 100 to 200 (10 per line) that are divisible by 5 or 6, but not both. Numbers are separated by exactly one space.
Fill in the blanks in each of the following statements: a) Computers process data under the control of sets of instructions called __________. b) The key logical units of the computer are the , , ,,...
What does the following program print? public class Mystery2 { public static void main(String[] args) { int count = 1; while (count
Based on the dangling-else discussion in Exercise 4.27, state the output for each of the following code segments when x is 9 and y is 11 and when x is 11 and y is 9. We eliminated the indentation...
Write a program that moves the ball in a pane. You should define a pane class for displaying the ball and provide the methods for moving the ball left, right, up, and down, as shown in Figure 15.26c....
Based on the dangling-else discussion in Exercise 4.27, modify the following code to produce the output shown. Use proper indentation techniques. You must not make any additional changes other than...
a) Sum the odd integers between 1 and 99, using a for statement. Assume that the integer variables sum and count have been declared. b) Calculate the value of 2.5 raised to the power of 3, using the...
Determine whether each statement is true or false. If false, explain why. a) Values of primitive types may be stored directly in a collection. b) A Set can contain duplicate values. c) A Map can...
The implementations of the methods contains(E e), get(int index), indexOf(E e), lastIndexOf(E e), and set(int index, E e) are omitted in the MyLinkedList class. Implement these methods. Define a new...
Credit card companies typically assign a special digit, called a check digit, to the end of each customers credit card number. The check digit allows companies to verify that the credit card number...
Define a new class named BSTWithBFT that extends BST with the following method: /** Display the nodes in a breadth-first traversal */ public void breadthFirstTraversal() Use...
In this exercise, you modify the Norbert Pool & Spa Depot application from Exercise 9. Use Windows to make a copy of the Norbert Solution-Introductory folder. Rename the copy Norbert...
Explain the difference between using a computer program and programming a computer.
Define the Triangle2D class that contains: Three points named p1, p2, and p3 of the type MyPoint with getter and setter methods. MyPoint is defined in Programming Exercise 10.4. A no-arg...
Rewrite Listing 21.9 to read the text from a text file. The text file is passed as a command-line argument. Words are delimited by whitespace characters, punctuation marks (,;.:?), quotation marks...
Write a program that prompts the user for a radius and then prints The area and circumference of a circle with that radius The volume and surface area of a sphere with that radius
Write a program that finds all prime numbers up to 10,000,000,000. There are approximately 455,052,511 such prime numbers. Your program should meet the following requirements: Your program should...
Write a program that animates the selection-sort algorithm. Create an array that consists of 20 distinct numbers from 1 to 20 in a random order. The array elements are displayed in a histogram, as...
For each of the following computations in Java, determine whether the result is exact, an overflow, or a roundoff error. a. 2.0 1.1 b. 1.0E6 * 1.0E6 c. 65536 * 65536 d. 1_000_000L * 1_000_000L
Develop a GUI application that displays Unicode characters, as shown in Figure 36.13. The user specifies a Unicode in the text field and presses the Enter key to display a sequence of Unicode...
An air conditioning unit in a car is being controlled by a microprocessor and a number of sensors. a) Describe the main differences between control and monitoring of a process. b) Describe how the...
The owner of a shop observes that on average 18 customers per hour arrive, and there are typically 8 customers in the shop. What is the average length of time each customer spends in the shop?
Easter Sunday is the first Sunday after the first full moon of spring. To compute the date, you can use this algorithm, invented by the mathematician Carl Friedrich Gauss in 1800: 1. Let y be the...
Compare the way Ada 95 provides polymorphism with that of C++, in terms of programming convenience.
What programming paradigm that nearly all recently designed languages support is not supported by Go?
Prove that every real number with a terminating binary representation (finite number of digits to the right of the binary point) also has a terminating decimal representation (finite number of digits...
Draw a flowchart for the algorithm in Exercise E3.14. Data from Exercise E3.14. Draw a flowchart for the algorithm in Exercise E3.13. Data from Exercise E3.13. Draw a flowchart for the algorithm in...
Write a program that prints a paycheck. Ask the program user for the name of the employee, the hourly rate, and the number of hours worked. If the number of hours exceeds 40, the employee is paid...
When a device interrupt occurs, how does the processor determine which device issued the interrupt?
Calculate the expected time for the following activities. Optimistic Most Likely Pessimistic Expected Time Activity Time Time Time A 3 7 11 13 D 16 E 4 18 F 11 G 4 H. 4 4 12 7 9 O23 5122N M13 24
In the Sequence interface of Worked Example 9.2, add static methods that yield Sequence instances: static Sequence multiplesOf(int n) static Sequence powersOf(int n) For example, Sequence.powersOf(2)...
The editor of a movie is finalising the music score. They will send the final version of the score to the movie producer by email attachment. a) Describe how sampling is used to record the music...
Now that the No Customer Escapes project team has been formed and a plan has been developed for distributing project information, Jim can begin working on the projects scope statement, workbook, and...
For each of the following examples, determine whether this is an embedded system, explaining why or why not. a. Are programs that understand physics and/or hardware embedded? For example, one that...
Figure 4-14 introduces the concept of affinity clustering. Suppose that through affinity clustering it was found that three business functions provided the bulk of the use of five data entities. What...
Consider the three DFDs in Figure 7-25. List three errors (rule violations) on these DFDs. E1 DF1 DF9 DF8 DF1 P1.1 P1.4.1 P1 DS1 DF11 P1.3 DF7 Level 0 DF3 DF2 DF3 Level 1 DF6 P1.2 Level 2 P1.4.2 DF10...
Interview a sample of project managers. Divide your sample into two small subsamples: one for managers of information systems projects and one for managers of other types of projects. Ask each...
Identify someone who manages an information systems project in an organization. Describe to him or her each of the skills and activities listed in Table 3-1. Determine which items he or she is...
Effective interviewing is not something that you can learn from just reading about it. You must first do some interviewing, preferably a lot of it, because interviewing skills improve only with...
Define the following terms: data, database, DBMS, database system, database catalog, program-data independence, user view, DBA, end user, canned transaction, deductive database system, persistent...
Use the outline for the BPP provided in Figure 5-9 to present the system specifications for the information system you chose for Problem and Exercise 5-35. Problem and Exercise 5-35. Consider your...
Draw an activity diagram for the following case. Maximum Software develops and supplies software products to individuals and businesses. As part of its operations, Maximum provides a 1-800 telephone...
Discuss the similarities and differences between an ontology and a database schema.
What aggregation feature is missing from the EER model? How can the EER model be further enhanced to support it?
Describe several projects you are involved in or plan to undertake, whether they are related to your education or to your professional or personal life (e.g., purchasing a new vehicle, learning a new...
Discuss the main differences between the notation for EER schema diagrams and UML class diagrams by comparing how common concepts are represented in each.
What is the relationship between a type and its subtype in a type hierarchy? What is the constraint that is enforced on extents corresponding to types in the type hierarchy?
Use BPMN to depict Hoosier Burgers food-ordering system from Figure 7-5 as a business process model. Figure 7-5 CUSTOMER KITCHEN 1.0 Customer Order Receive and Transform Food Order Receipt Customer...
Discuss the various type constructors. How are they used to create complex object structures?
Discuss the different ways for looping over a query result in PHP.
Discuss the main functions for accessing a database in PEAR DB, and how each is used.
What are PHP auto-global variables? Give some examples of PHP autoglobal arrays, and discuss how each is typically used.
What is the impedance mismatch problem? Which of the three programming approaches minimizes this problem?
How do regular inheritance, multiple inheritance, and selective inheritance differ?
Draw a class diagram, showing the relevant classes, attributes, operations, and relationships for each of the following situations (if you believe that you need to make additional assumptions,...
What are the differences between the use of tags in XML versus HTML?
What is the difference between attributes and elements in XML? List some of the important attributes used to specify elements in XML schema.
Draw a use case diagram for the situation described in Problem and Exercise 7-40. Problem and Exercise 7-40 Starting with a context diagram, draw as many nested DFDs as you consider necessary to...
Draw a use case diagram for the situation described in Problem and Exercise 7-42. Problem and Exercise 7-42 Develop a context diagram and a level-0 diagram for the contracting system described in the...
At a local bank, loan officers must evaluate loan applications before approving or denying them. During this evaluation process, many factors regarding the loan request and the applicants background...