Create the shoutbox class for your virtual world

Assignment Help Data Structure & Algorithms
Reference no: EM13499195

You will create the ShoutBox class for your Virtual World. Your ShoutBox class will have two methods:

Method shoutOutCannedMessage() will return type String. The shoutOutCannedMessage will use an Array or an ArrayList to store 10 messages of type String. For those of you who are more advanced with your Java skills, you could use a HashMap for the data structure. You can load this data structure with 10 messages of your choosing. You can initialize your Array or ArrayList with the messages or have the user enter the messages. The choice is yours. shoutOutCannedMessage() will loop through the data structure to first display all canned messages and allow the user to select one. The shoutOutCannedMessage() will return the selected message String.

The shoutOutRandom Message() method will return type String.

The shoutOutRandomMessage() will use several Arrays or an ArrayList to store words. You will have one data structure that holds a list of words that are subjects, another data structure that holds a list of words that are objects, another that holds a list of verbs, another that holds a list of adverbs, and another that holds a list of adjectives. You can initialize your data structures with words or have the user enter the words. The choice is yours.

The shoutOutRandomMessage() method will use a random number generator that selects one word from each data structure to form a random message. The shoutOutRandomMessage() method will return the random message as a String data type. Random messages will be of the form: Subject - Verb - Adjective - Object - Adverb. Document your shoutOutRandomMessage() method to explain the code.

Reference no: EM13499195

Questions Cloud

Create a fictional start-up company : Provide a detailed description of your company. The description should include, at a minimum, the company's name, its history, founders, business purpose, and mission.
Historical transitioning and growth of the u.s. health care : Historical Transitioning and Growth of the U.S. Health Care System
Explain what mass of mgnh4po4 precipitated : what mass of MgNH4PO4 precipitated when 200 mL of 1%(w/v) solution of MgCl2 were treated with 40 mL of 0.1753 M Na3PO4 and excess of NH4+ what was the molarity of the excess reagent (Na3PO4 or MgCl2) after the precipitation was complete
Find the post-collision angular speed : A small blob of putty of mass m=12 g falls from the ceiling and lands on the outer rim of a turntable of radius R= 20 cm, find the post-collision angular speed of the turntable-putty system
Create the shoutbox class for your virtual world : Create the ShoutBox class for your Virtual World. Your ShoutBox class will have two methods - initialize your data structures with words or have the user enter the words
Explain what is the concentration of in mass percent : An aqueous solution has a vapor pressure of 82.6 at 50 . The vapor pressure of pure water at this temperature is 92.6. What is the concentration of in mass percent
Determine the rms current in this circuit : A 451-? resistor and a 257-mH inductor are connected in series with an ac generator with an rms voltage of 20.0 V and a frequency of 60.0 Hz
Explain the width of a 1275 gram piece of aluminum : What is the width of a 1275 gram piece of aluminum with an area of 18.5 square meters and a density of 2.7 g/cc
Compute the heat generated in the rod : A rod of 2.0-m length and a square (2.0 mm x 2.0 mm) cross section is made of a material with a resistivity of 6.0 x 10 ^-8 ohms m. What is heat generated in the rod

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  Demonstrate a decision tree or table

Demonstrate a decision tree or table

  Write down the output values and number of instances

Write down the output (class) values and number of instances that appear in each of the leaf nodes A, B and C of the tree.

  Creating visual studio asp .net web site

Make a Visual Studio 2008 ASP .NET Web Site with 2-Web Forms. Add a DropDownList server control and a Label server control to 1st Web Form.

  Devise a linear-time algorithm to count the parallel edges

Devise a linear-time algorithm to count the parallel edges in a graph. Write the algorithm in pseudocode.

  Algorithm for locating nth successor in circlar linked list

Write algorithm or code segment for locating nth successor of an item in circlar linked list (the nth item that follows the given item in the list).

  Create a flowchart to show the process that will allow the

1.create a flowchart to show the process that will allow the implementation of stack push and pop operations.2.create a

  Compares the number of comparisons used by various data

compares the number of comparisons used by various data structures for a single algorithm. the algorithm is the one

  Using a linked implementation of graph prepare a method

using a linked implementation of graph prepare a method checkpath that takes two nodes as input. the method must

  Data structures and algorithms

Provides learners with an understanding of how data structures are used in algorithms and enables them to design and implement data structures

  Computing time complexity of procedure

What is the time complexity of the procedure? If A[l .. r] = [24, 30, 09, 46, 15, 19, 29, 86,78], what is the output?

  Create divide and conquer algorithm to solve problem

Create a divide and conquer algorithm to solve problem. The time complexity of your algorithm must be O(nlgn) or better.

  Using pseudocode, design an algorithm

BuzzButtons is a novelty item company manufacturing personalized lapel buttons. The owner is promoting his buttons by offering them at 99 cents each. He wants you to design a program asking the user for his or her name for the button, an e-mail addre..

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd