Consider a periodic signal x(t) with fundamental period T 0 =1 and a period x 1 (t) = 0.5t[u(t) u(t 1)]. (a) Consider the derivative g(t) = dx(t)/dt. Indicate if g(t) is periodic and if so give its...
Suppose that in a Bayesian network containing an unobserved variable Y, all the variables in the Markov blanket MB(Y) have been observed. a. Prove that removing the node Y from the network will not...
In each case, determine the problem and fix the errors. After you correct the errors, save each file using the same filename preceded with Fix. For example, DebugOne1.java will become...
Write an application that prompts a user for two integers and displays every integer between them. Display a message if there are no integers between the entered values. Make sure the program works...
Write a program that inserts parentheses, a space, and a dash into a string of 10 user-entered numbers to format it as a phone number. For example, 5153458912 becomes (515) 345-8912. If the user does...
Write an application that accepts a word from a user and converts it to Pig Latin. If a word starts with a consonant, the Pig Latin version removes all consonants from the beginning of the word and...
a. The mean of a list of numbers is its arithmetic average. The median of a list is its middle value when the values are placed in order. For example, if an ordered list contains 1, 2, 3, 4, 5, 6,...
Create a class named Poem that contains fields for the name of the poem and the number of lines in it. Include a constructor that requires values for both fields. Also include get methods to retrieve...
a. Write an application that displays a JFrame containing the opening sentence or two from your favorite book. Save the file as JBookQuote.java. b. Add a button to the frame in the JBookQuote...
In this exercise, you will complete the Moonbucks application that you created in Exercise 2 in Chapter 2. a. Use Windows to copy the Moonbucks Solution folder from the VB2017\Chap02 folder to the...
Write a server for a client. The client sends the weight and height for a person to the server (see Figure 31.18a). The server computes BMI (Body Mass Index) and sends back to the client a string...
In a side-scrolling video game, a character moves through an environment from, say, left-to-right, while encountering obstacles, attackers, and prizes. The goal is to avoid or destroy the obstacles,...
Professor Amongus has shown that a decision problem L is polynomial-time reducible to an NP-complete problem M. Moreover, after 80 pages of dense mathematics, he has also just proven that L can be...
a. Design the logic for a program that allows a user to enter 20 numbers, then displays each number and its difference from the numeric average of the numbers entered. b. Modify the program in...
Design the application logic for a company that wants a report containing a breakdown of payroll by department. Input includes each employees department number, hourly salary, and number of hours...
Modify the Student class in Listing 8.2 so that it implements the comparable interface. Define the compareTo method to order Student objects based on the value in studentNumber. In a main method...
Create an application using the following names for the solution and project, respectively: Chopkins Solution and Chopkins Project. Save the application in the VB2015\Chap03 folder. Change the form...
Consider a database that consists of the following relations. SUPPLIER(Sno, Sname) PART(Pno, Pname) PROJECT(Jno, Jname) SUPPLY(Sno, Pno, Jno) The database records information about suppliers, parts,...
a. Sunshine Seashore Supplies rents beach equipment such as kayaks, canoes, beach chairs, and umbrellas to tourists. Write a program that displays Sunshines motto, which is Sunshine Seashore makes it...
Consider the following instruction mix: 1. What fraction of all instructions use data memory? 2. What fraction of all instructions use instruction memory? 3. What fraction of all instructions use the...
We need to swap the following registers. Do this using block moves. Before r1 r2 r3 r4 r5 r6 r7 After r3 r4 r5 r6 r7 r1 r2
A signal e(t) is sampled by the ideal sampler as specified by . (a) List the conditions under which e(t) can be completely recovered from e*(t) , that is, the conditions under which no loss of...
Evaluate the function \(f(x, y)=\frac{2}{3} e^{-x / 2} \cos (y-1)\) for \(x=-0.23, y=2.7\) by: a. Using the subs command. b. Conversion into a MATLAB function.
Assume that we would like to expand the MIPS register file to 128 registers and expand the instruction set to contain four times as many instructions. 1. How this would this affect the size of each...
The PredatoryCreditCard class provides a processMonth( ) method that models the completion of a monthly cycle. Modify the class so that once a customer has made ten calls to charge during a month,...
Give an example of a worst-case sequence with n elements for insertion-sort, and show that insertion-sort runs in (n 2 ) time on such a sequence.
Compare and contrast byte-oriented and bit-oriented protocols.
In an 802.11, give the value of the address 1 field in each of the following situations (left bit defines To DS and right bit defines From DS). a. 00 b. 01 c. 10 d. 11
In distance-vector routing, bad news (increase in a link metric) will propagate slowly. In other words, if a link distance increases, sometimes it takes a long time for all nodes to know the bad...
In HTTP, draw a figure to show the application of cookies in a web portal using two sites.
One challenge for architects is that the design created today will require several years of implementation, verification, and testing before appearing on the market. This means that the architect...
Add a column named Base_salary with a datatype of NUMBER(7,2) to the STORE_REPS table. Ensure that the amount entered is above zero.
Attempt to log in to Oracle 12c with the newly created account.
The Marketing Department of JustLee Books is preparing for its annual sales promotion. Each customer who places an order during the promotion will receive a free gift with each book purchased. Each...
Which of the following SQL statements displays a customers name in all uppercase characters? a. SELECT UPPER ('firstname', 'lastname') FROM customers; b. SELECT UPPER (firstname, lastname) FROM...
Which of the following is a valid SELECT statement? a. SELECT AVG (retail-cost) FROM books GROUP BY category; b. SELECT category, AVG (retail-cost) FROM books; c. SELECT category, AVG (retail-cost)...
Given the message AACCCBCCDDAB, in which the probabilities of symbols are P(A) = 0.50, P(B) = 0.25, P(C) = 0.125, and P(D) = 0.125, a. encode the data using Huffman coding. b. find the compression...
In a real-time multimedia communication, assume we have one sender and ten receivers. If the sender is sending multimedia data at 1 Mbps, how many RTCP packets can be sent by the sender and each...
In general, how can you transform a relation not in BCNF into ones that are in BCNF?
Are reflex actions (such as flinching from a hot stove) rational? Are they intelligent?
Consider the family of generalized tic-tac-toe games, defined as follows. Each particular game is specified by a set S of squares and a collection W of winning positions. Each winning position is a...
a. Create an application named Percentages whose main() method holds two double variables. Assign values to the variables. Pass both variables to a method named computePercent() that displays the two...
In each case, determine and fix the problem. After you correct the errors, save each file using the same filename preceded with Fix. For example, DebugThree1.java will become FixDebugThree1.java. a....
Create a class that holds data about a job applicant. Include a name, a phone number, and four Boolean fields that represent whether the applicant is skilled in each of the following areas: word...
a. Write an application that accepts three Strings from the user and, without regard to case, appropriately displays a message that indicates whether the Strings were entered in alphabetical order....
Three-letter acronyms are common in the business world. For example, in Java you use the IDE (Integrated Development Environment) in the JDK (Java Development Kit) to write programs used by the JVM...
You modified the RentalDemo program for Sammys Seashore Supplies to accept and display data for an array of three Rental objects. Now, modify the program to use an array of eight Rental objects....
Micks Wicks makes candles in various sizes. Create a class for the business named Candle that contains data fields for color, height, and price. Create get methods for all three fields. Create set...
Create a CourseException class that extends Exception and whose constructor receives a String that holds a college courses department (for example, CIS), a course number (for example, 101), and a...
If a transmitting computer sends an 8-bit binary message 11000111 using an even parity bit. Write the 9-bit data with the parity bit in the most significant bit. If the receiving computer receives...
Using DeMorgans theorem, draw logic diagrams for ABC + AB + BC (a) Using only AND gates and inverters. (b) Using only OR gates and inverters. You may use two-input and three-input AND and OR gates...
Using De Morgan equivalent gates and bubble pushing methods, redraw the circuit in Figure 2.83 so that you can find the Boolean equation by inspection. Write the Boolean equation. B- C- D- E- Dor...
Implement a function that accepts a PositionalList L of n integers sorted in nondecreasing order, and another value V, and determines in O(n) time if there are two elements of L that sum precisely...
Implement the preorder method in BST using a stack instead of recursion. Write a test program that prompts the user to enter 10 integers, stores them in a BST, and invokes the preorder method to...
Find out what networks are used at your school or place of work. Describe the network types, topological, and switching methods used there.
Look at the computer ads on the business pages of a large daily newspaper and make a list of all the terms used that you dont understand. Save this list and check it from time to time during the...
In this exercise, you modify one of the Waterson Company applications from this chapters Apply lesson. Use Windows to make a copy of the Waterson Solution-Highest folder. Rename the copy Waterson...
Bill has an algorithm, find2D, to find an element x in an n n array A. The algorithm find2D iterates over the rows of A and calls the algorithm arrayFind, of Algorithm 1.12, on each one, until x is...
Solve the previous exercise using a queue instead of stack. That is, suppose you are given an array, A, containing n numbers in order, as in the previous exercise. Describe in pseudocode an efficient...
Give an example set of 10 characters and their associated frequencies so that, in the Huffman tree for this set, every internal node has an external-node child.
In this exercise, you will create a program that displays a table consisting of four rows and three columns. The first column should contain the numbers 10 through 13. The second and third columns...
In this exercise, you will create a program that allows the user to enter an unknown number of sales amounts for each of three car dealerships: Dealership 1, Dealership 2, and Dealership 3. Use a...
Assume you have created a mechanical arm that can hold a pen. The arm can perform the following tasks: Lower the pen to a piece of paper. Raise the pen from the paper. Move the pen 1 inch along a...
Assume that the following variables contain the values shown: numberBig = 100 numberMedium = 10 numberSmall = 1 wordBig = "Constitution" wordMedium = "Dance" wordSmall = "Toy For each of the...
Your downloadable files for Chapter 5 include a file named DEBUG05-04.jpg that contains a flowchart with syntax and/or logical errors. Examine the flowchart and then find and correct all the bugs.
Complete the following tasks: a. Design a class named Cake. Data fields include two string fields for cake flavor and icing flavor and numeric fields for diameter in inches and price. Include methods...
An int can hold integers only up to a maximum number. Find an approximation of that maximum number by using fibonacci().
Extend your solution to Exercise 2.21 to build an abstract syntax tree directly, without constructing a parse tree first. Data From exercise 2.21: Build a complete recursive descent parser for the...
Define a utility class for displaying values of type double. Call the class DoubleOut. Include all the methods from the class DollarFormat in Listing 6.14, all the methods from the class OutputFormat...
A biologist determines that the approximate number, Number, of bacteria present in a culture after a certain number of days, Time, is given by the following formula: Number = BacteriaPresent *...
A university posts its employees salaries at http:// liveexample.pearsoncmg.com/data/Salary.txt. Each line in the file consists of a faculty members first name, last name, rank, and salary (see...
The implementations of the methods addAll, removeAll, retainAll, toArray(), and toArray(T[]) are omitted in the MyList interface. Implement these methods. Test your new MyList class using the code at...
Define a new class named BSTWithNumberOfNonLeaves that extends BST with the following methods: /** Return the number of nonleaf nodes */ public int getNumberofNonLeaves() Use...
A year with 366 days is called a leap year. Leap years are necessary to keep the calendar synchronized with the sun because the earth revolves around the sun once every 365.25 days. Actually, that...
Jim Watanabe looked around his new office. He couldnt believe that he was the assistant director of information technology at Petrie Electronics, his favorite consumer electronics retail store. He...
List the deliverables from the conceptual data modeling part of the analysis phase of the systems development process.
What are the six guidelines to follow when drawing DFDs?
What are the advantages of online and batch processing, respectively?
Find a current example of a large-scale grid computing project and describe it in as much detail as you can. What is the purpose of the project? What is the problem being addressed? How is grid...
Figure 12-26 shows two typical executions of a program that displays a triangle. Create this program by prompting the user for a number of lines to display. The first row of the output contains the...
Assuming you have declared shoeSize to be a variable of type int, which of the following is a valid assignment statement in Java? a. shoeSize = 9; b. shoeSize = 9.5; c. shoeSize = "nine"; d. shoeSize...
Imagine that the problem in Exercise 3.ROMF, in which two friends try to meet up on the map of Romania, is modified so that one of the friends wants to avoid the other. The problem then becomes a...
Write a symbolic microprogram routine for the ISZ (increment and skip if zero) instruction defined in Chap. 5 (Table 5-4). Use the microinstruction format of Sec. 7-3. Note that DR = 0 status...
Write the MIPS assembly code to implement the following C code as an atomic set max operation using the lI/sc instructions. Here, the argument shvar contains the address of a shared variable, which...
Consider a proposed new instruction named rpt. This instruction combines a loops condition check and counter decrement into a single instruction. For example, rpt $s0, loop would do the following: if...
For the following C statement, write a minimal sequence of MIPS assembly instructions that does the identical operation. Assume $t0 = A and $s0 is the base address of C. A = C[0] < < 4;
Find a state-variable formulation for the system described by the coupled second-order difference equations given. The system output is y(k) , and e 1 (k) and e 2 (k) are the system inputs. y(k) =...
Brewsters Used Cars, Inc. employs several salespeople. Brewster, the owner of the company, has provided a file that contains sales records for each salesperson for the past month. Each record in the...
Calculate the time necessary to perform a multiply using the approach given in Figures 3.3 and 3.4 if an integer is 8 bits wide and each step of the operation takes 4 time units. Assume that in step...
Describe in detail an algorithm for reversing a singly linked list L using only a constant amount of additional space.
In Figure 9.7, do you think that system A should first check its cache for mapping from N2 to L2 before even broadcasting the ARP request? Figure 9.7 Figure 9.7 ARP operation LAN System A System B...
Manually simulate the Fletcher algorithm (Figure 10.18) to calculate the checksum of the following bytes: (2B) 16 , (3F) 16 , (6A) 16 , and (AF) 16 . Also show that the result is a weighted checksum....
Repeat Problem P16-9 for D-AMPS. Problem P16-9 Find the efficiency of AMPS in terms of simultaneous calls per megahertz of bandwidth. In other words, find the number of calls that can be used in...
Combine the following three blocks of addresses into a single block: a. 16.27.24.0/26 b. 16.27.24.64/26 c. 16.27.24.128/25
Router A sends two RIP messages to two immediate neighboring routers, B and C. Do the two datagrams carrying the messages have the same source IP addresses? Do the two datagrams have the same...
Assume the shortest path in a graph from node A to node H is A B H. Also assume that the shortest path from node H to node N is H G N. What is the shortest path from node A to node N?
Find the interface identifier if the Ethernet physical address is (F5-A9-23-12-7A-B2) 16 using the format we defined for Ethernet addresses.
Which tables and fields would you access to determine which book titles have been purchased by a customer and when the order shipped? Figure 1-5: ORDERS Order# Customer# Orderdate Shipdate Shipstreet...
Add a new row in the ORDERS table with the following data: Order# = 1022, Customer# = 2000, and Order date = August 6, 2009. Describe the error raised and what caused the error.