Create shoutbox class for your virtual world.

Assignment Help C/C++ Programming
Reference no: EM13939809

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 shoutOutRandomMessage() 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: EM13939809

Questions Cloud

Was the british pound selling at a discount or premium : What was the 90-day forward premium (or discount)?  Was the British pound selling at a discount or premium in the forward market?
Calculate a firms cost of equity : Consider one of the two equations that can be used to calculate a firm's cost of equity: rE=Div1/P0+g. If the expected growth rate of American Airlines common stock dividends increases and if the price of AAL's stock also increases, what happens to A..
Transaction costs and taxes : The price of ABC stock is currently $42 per share, but in six months you expect it to rise to $50. ABC does not pay a dividend. You buy a six-month call on ABC, with a strike price of $45. The option cost $200. What holding period return do you expec..
What are the dividends per share-earnings per share : Billy’s Exterminators, Inc., has sales of $752,000, costs of $312,000, depreciation expense of $64,000, interest expense of $42,000, a tax rate of 35 percent, and paid out $57,600 in cash dividends. The firm has 120,000 shares of common stock outstan..
Create shoutbox class for your virtual world. : The shoutOutRandomMessage() method will use a random number generator that selects one word from each data structure to form a random message
Motivation for adult online learning : What motivate adults to enroll in online education - This article is about how online course designers/programmers have change programs to allow students have more settings to allow the student to have more flexibility in how they learn.
Compute aztec departmental overhead rate : Aztec Industries produces bread which goes through two operations, mixing and baking, before it is ready to be packaged. Next year's expected costs and activities are shown below.
Normally pays an annual dividend : MMK Cos. normally pays an annual dividend. The last such dividend paid was $2.15, all future dividends are expected to grow at a rate of 8 percent per year, and the firm faces a required rate of return on equity of 14 percent. If the firm just announ..
Problem regarding the series of multiple alleles : Plumage in ducks is determined to some extent by a series of multiple alleles named restricted (MR = white on the wing fronts), mallard (M = wild type), and dusky (md = darker plumage). MR is dominant to M, which is dominant to md

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Write a hexadecimal integer literal

Write a hexadecimal integer literal representing the value fifteen.

  Give brief definition of the database concept

First let us start with a brief definition of the Database concept. A database is a collection of data records stored in a computer in a systematic way. In this way, a computer program can be used to answer queries about the data stored in the dat..

  Design customized mailing lists for marketing department

Marketing department requires to be able to design customized mailing lists, to send different messages to different types of donors. What system will best meet these requirements?

  Called cbankaccount

Create a base class, called CBankAccount, and two additional classes (each derived from CBankAccount), called CSavingsAccount and CCheckingAccount.

  A program that tests the users ability to memorize

a program that tests the user's ability to memorize a sequence of colors

  Write a recursive and iterative versions of binary search

In C++ write a recursive and iterative versions of binary search and compare their run times using the array a[i]=i, i=0,..., n-1 and the given test method:

  Object oriented app development

Object Oriented App development

  Correct code so that it finds the sum of 20 numbers

Correct the following code so that it finds the sum of 20 numbers.

  A parking garage charges a $2.00 minimum

A parking garage charges a $2.00 minimum fee to park for up to three hours and an additional $0.50 per hour for each hour or part thereof over three hours.

  Digital filtering

Write a main code that reads filter coefficient data from the file filter.txt and creates a filter, reads an input float_seq from the file input.txt, filters the input float_seq using the filterand then writes the output float_seq to the file, output..

  Compute the average of each row

Write a program that prompts the user to enter 15 double numbers from the keyboard and save them into a 3 by 5 array in the main ( ). Then call a user-define function to compute the average of each row and print the original matrix and average of ..

  Null pointer problem

What is the only thing that you should ever do with the NULL pointer? In the following declaration, explain what type p is, and describe how it might be used.

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