Browse W
Alphabetical listing with fast deep pagination.
66619 items • Page 976 / 1333
Write a class (and a client class to test it) that encapsulates a tic-tac-toe bo
Write a class (and a client class to test it) that encapsulates a tic-tac-toe board. A tic-tac-toe board looks like a table of three rows and three columns partially or completely…
Write a class (and a client class to test it) that encapsulates statistics for s
Write a class (and a client class to test it) that encapsulates statistics for summer job salaries for a group of people over several years. Your ONLY instance variable should be …
Write a class (and a client class to test it) that encapsulates statistics for s
Write a class (and a client class to test it) that encapsulates statistics for summer job salaries for a group of people over several years. Your only instance variable should be …
Write a class (and a client class to test it) that encapsulates statistics for s
Write a class (and a client class to test it) that encapsulates statistics for summer job salaries for a group of people over several years. Your only instance variable should be …
Write a class (and a client class to test it) that encapsulates the evolution of
Write a class (and a client class to test it) that encapsulates the evolution of the sales tax rates in the 50 U.S. states over the last 10 years. Your only instance variable shou…
Write a class (with a main method) called AppleTest Declare 2 double variables n
Write a class (with a main method) called AppleTest Declare 2 double variables named: interest Amount and new Balance Declare an object of the above class AppieAccount called "acc…
Write a class AVLComparator which implements comparator and is used to compare t
Write a class AVLComparator which implements comparator and is used to compare two AVLNode instances. Note that one (or both) instances might be null. Treat null instances as if t…
Write a class Account to manage a bank account. Each account should have an acco
Write a class Account to manage a bank account. Each account should have an account number (an int). One should be able to make deposits and withdrawals and read out the balance. …
Write a class AmazonOrder which keeps track of the items a person orders on Amaz
Write a class AmazonOrder which keeps track of the items a person orders on Amazon. We want to be able to add an item of a specific cost and remove an item of a specific cost. We …
Write a class ArithmeticExpressionEvaluator that evaluates an infix arithmetic e
Write a class ArithmeticExpressionEvaluator that evaluates an infix arithmetic expression. Do this in two steps. First, convert the infix expression to a postfix expression:create…
Write a class ArithmeticExpressionEvaluator that evaluates an infix arithmetic e
Write a class ArithmeticExpressionEvaluator that evaluates an infix arithmetic expression. Do this is two steps. First, convert the infix expression to a postfix expression: creat…
Write a class ArithmeticExpressionEvaluator that evaluates an infix arithmetic e
Write a class ArithmeticExpressionEvaluator that evaluates an infix arithmetic expression. Do this is two steps. first, convert the infix expression of a postfix expression: creat…
Write a class Array with a constructor and two methods: Array(double[] array): c
Write a class Array with a constructor and two methods: Array(double[] array): constructor that stores array into a member variable (field). double sum(): computes the sum of the …
Write a class ArrayList that represents an array of integers. Initially it has a
Write a class ArrayList that represents an array of integers. Initially it has a capacity of 1 and is “empty”. At any time, it can be partially full, so it keeps track of its curr…
Write a class ArrayList that represents an array of integers. Initially it has a
Write a class ArrayList that represents an array of integers. Initially it has a capacity of 1 and is “empty”. At any time, it can be partially full, so it keeps track of its curr…
Write a class AveragingNumbers with the following static methods // The followin
Write a class AveragingNumbers with the following static methods // The following method takes the original array, and // uses Arrays.sort to create a new, sorted array. // origin…
Write a class BCheckString that is derived from the STL string class. This new c
Write a class BCheckString that is derived from the STL string class. This new class will have two member functions: A) A BCheckString(string s) constructor that receives a string…
Write a class Book that has the following private data members: a string title a
Write a class Book that has the following private data members: a string title a string author Write getters and setters for each of the data members. They should follow the namin…
Write a class Box that contains instance data: width, height, and depth. Define
Write a class Box that contains instance data: width, height, and depth. Define Box’s constructor to accept and initialize all instance data. Provide the following methods in the …
Write a class Bug that models a bug moving along a horizontal line. The bug move
Write a class Bug that models a bug moving along a horizontal line. The bug moves either to the right or left. Initially, the bug moves to the right but at random times it will tu…
Write a class Bug that models a bug moving in the x-y plane. The bug either move
Write a class Bug that models a bug moving in the x-y plane. The bug either moves north, east, south, or west. Initially, the bug moves to the north, but it can turn to the right …
Write a class Calc that will evaluate simple arithmetic expressions. However, in
Write a class Calc that will evaluate simple arithmetic expressions. However, instead of the usual arithmetic functions (+, *, -, /), your code must evaluate expressions with the …
Write a class Card. A Card has the following private attributes: • A String suit
Write a class Card. A Card has the following private attributes: • A String suit. • An int value. There are four possible options for suits: hearts, spades, clubs, and diamonds. T…
Write a class Complex to represent complex numbers in java. Objects of the type
Write a class Complex to represent complex numbers in java. Objects of the type Complex should be described to to fields, re and im of the type double. The two fields re and im sh…
Write a class CourseListException that extends Exception with the following cons
Write a class CourseListException that extends Exception with the following constructors: A default constructor that gives the error message "Too many courses." A constructor that…
Write a class Cow that keeps track of the current weight of a cow (as an \"int\"
Write a class Cow that keeps track of the current weight of a cow (as an "int" value, in pounds). The Cow class should have a constructor, set and get methods, and a toString meth…
Write a class DNASequence that has the following: a. Instance Variables 1. Name-
Write a class DNASequence that has the following: a. Instance Variables 1. Name- the name of the creature the DNA belongs. 2. Sequence-a string which can only have the characters …
Write a class DataSet that stores a number of values of type double. Provide a c
Write a class DataSet that stores a number of values of type double. Provide a constructor public DataSet(int maxNumberOfValues) and a method public void addValue(double value) th…
Write a class DataSet that stores a number of values of type double. Provide a c
Write a class DataSet that stores a number of values of type double. Provide a constructor public DataSet(int maxNumberOfValues) and a method public void addValue(double value) th…
Write a class DateSwitcher with a single main method. Inside main, write code th
Write a class DateSwitcher with a single main method. Inside main, write code that, given a local String variable containing a date of the form "2/7/2009", parses each field and p…
Write a class DepthFirstPaths.java to implement a Depth First Search algorithm u
Write a class DepthFirstPaths.java to implement a Depth First Search algorithm using the pseudocode given below. Alternatively you can download the file DepthFirstPaths.java and i…
Write a class Family that has the attributes Income: a double value that is the
Write a class Family that has the attributes Income: a double value that is the income for the family Size: the number of people in the family and the following methods: Family(in…
Write a class For implementing a simple binary search tree capable of storing nu
Write a class For implementing a simple binary search tree capable of storing numbers. The class should have member functions: void insert (double x) bool search(double x) void in…
Write a class For implementing a simple binary search tree capable of storing nu
Write a class For implementing a simple binary search tree capable of storing numbers. The class should have member functions: void insert (double x) bool search(double x) void in…
Write a class For implementing a simple binary search tree capable of storing nu
Write a class For implementing a simple binary search tree capable of storing numbers. The class should have member functions: void insert (double x) bool search (double x) void i…
Write a class For implementing a simple binary search tree capable of storing nu
Write a class For implementing a simple binary search tree capable of storing numbers. The class should have member functions: void insert (double x) bool search (double x) void i…
Write a class Fraction that defines adding, subtracting multiplying and dividing
Write a class Fraction that defines adding, subtracting multiplying and dividing fractions by overloading standard operators for these operations. Write a function member for red…
Write a class HeaderParser that is a subclass of the HTMLParser class. It will f
Write a class HeaderParser that is a subclass of the HTMLParser class. It will find and collect the contents of all the headings in an HTML file fed to it. The parser works by ide…
Write a class Heading that can be used to store one of the principal compass dir
Write a class Heading that can be used to store one of the principal compass directions, 'N', 'E', 'S', 'W'. It will have the following methods Constructor-builds a Heading as one…
Write a class Heading that can be used to store one of the principal compass dir
Write a class Heading that can be used to store one of the principal compass directions, 'N', 'E', 'S', 'W'. It will have the following methods. Constructor-builds a Heading as on…
Write a class Hyena that extends the Critter class, along with its movement and
Write a class Hyena that extends the Critter class, along with its movement and eating behavior. All unspecified aspects of Hyena use the default behavior. Write the complete clas…
Write a class IntegerMath with a single method that takes three integers as para
Write a class IntegerMath with a single method that takes three integers as parameters. Use if and else to select and return only the largest of the three integers. Make sure that…
Write a class JuniorSalesman that inherits from Hourly (Listing 10.7 is availabl
Write a class JuniorSalesman that inherits from Hourly (Listing 10.7 is available online in examples from textbook "Java Software Solutions by Lewis and Lofrus"). A JuniorSalesman…
Write a class LapTimer that can be used to time the laps in a race. The class sh
Write a class LapTimer that can be used to time the laps in a race. The class should have the following private attributes: running-a boolean indication of whether the timer is ru…
Write a class LapTimer that can be used to time the laps in a race. The class sh
Write a class LapTimer that can be used to time the laps in a race. The class should have the following member variables (all private): running - a boolean indication of whether t…
Write a class Lightsaber and become a Jedi Master, or Sith lord. Example Dialog:
Write a class Lightsaber and become a Jedi Master, or Sith lord. Example Dialog: To become a Jedi, one must build a light saber. Let's test to see if you have constructed yours p…
Write a class Lines containing a static method dashedLine to draw dashed lines,
Write a class Lines containing a static method dashedLine to draw dashed lines, so it can write: Lines,dashedLine(g, xA, yA, xB, yB, dashLength); where g is a variable of type Gra…
Write a class Lines containing a static method dashedLine to draw dashed lines,
Write a class Lines containing a static method dashedLine to draw dashed lines, so it can write: Lines,dashedLine(g, xA, yA, xB, yB, dashLength); Where g is a variable of type Gra…
Write a class LinkedBag, which includes the following operations create an empty
Write a class LinkedBag, which includes the following operations create an empty bag test if a bag is empty get the number of items of a bag get the frequency of items in a bag in…
Write a class ListParser that is a subclass of the HTMLParser class. It will fin
Write a class ListParser that is a subclass of the HTMLParser class. It will find and collect the contents of all the list items, both ordered and unordered, in an HTML file fed i…