Write the girlscout class assuming a girl scout object

Assignment Help Computer Graphics
Reference no: EM13329276

In this exercise, you will write a class that models a Girl Scout cookie seller and use your class to update sales of cookies in a GUI program.

1.Write the GirlScout class assuming a girl scout object is described by two pieces of instance data:name of girl scout(a String) andboxesSold(an integer that represents the number of boxes of cookies the girl scout has sold in the fundraiser).

The class should have the following methods:

·A constructor that has one parameter-a String containing the name of the girl scout. The constructor should set boxesSold to 0.

·A methodgetNamethat returns the name of the girl scout (it has no parameters).

·A method that updates the number of boxes sold called updateBoxesSold that takes in single parameter, representing the number of additional boxes of cookies sold.

·A method update Sales that takes no parameters and just multiplies the boxesSold by 3.50.

·A to String method that returns a string containing the name of the girl scout and the number of boxes of cookies sold in a format similar to the following:

Margie: 16 boxes

 

Reference no: EM13329276

Questions Cloud

Find how far from the girls initial position do they meet : A girl with mass m1 and a sled with mass m2 are on the frictionless ice of a frozen lake, How far from the girl's initial position do they meet
It department to meet the organization needs : If you were selected to be the CIO of an organization, what elements would you consider in building an appropriate IT department to meet the organization's needs?
Determine what amount must friend deposit annually : Your friend intends to invest her money in the local credit union, which offers 7.9 percent interest per year. She wants to make equal annual payments on each birthday into the account established at the credit union for her retirement fund.
What is the magnitude of the bodys acceleration : Only two horizontal forces act on a 6.3 kg body. One force is 6.0 N, acting due east, and the other is 8.3 N, What is the magnitude of the body's acceleration?
Write the girlscout class assuming a girl scout object : Write the GirlScout class assuming a girl scout object is described by two pieces of instance data:name of girl scout(a String) andboxesSold(an integer that represents the number of boxes of cookies the girl scout has sold in the fundraiser).
Find how much work is done by such proteins : Biological muscle cells can be thought of as nanomotors that use the chemical energy of ATP to produce mechanical work. How much work is done by such proteins
Calculate her altitude as she crosses the bar : A 54-kg pole vaulter running at 11 m/s vaults over the bar. Her speed when she is above the bar is 1.7 m/s, determine her altitude as she crosses the bar
Utilize your knowledge of supply-demand analysis and show : Utilize your knowledge of supply/demand analysis and show graphically the impact of a government minimum wage of $6 hour with a market wage for unskilled workers of $7 hour with 1 million workers employed at the market wage.
Part of domestic or municipal law : Explain this statement and give particular examples of treaties ratified by the Australian government which have become part of domestic or municipal law.

Reviews

Write a Review

Computer Graphics Questions & Answers

  Create a simple warm-up program using your g3d

Create a simple warm-up program using your G3D programming and graphics environment.

  Shadow effect while rolling a sphere

Shadow effect while rolling a sphere as well as the options of shading and lighting.

  Relative positioning and interactive positioning

Relative Positioning and Interactive Positioning by Dragging and Clicking and some Simple Animation

  Draw a teapot at the global origin

Draw a teapot at the global origin

  Concepts of computer graphics

Concepts of Computer Graphics and develop a program using OpenGL

  The security policy document outline

Using the GDI Case Study below, complete the Security Policy Document Outline

  Develop the image manipulations

Develop the image manipulations

  What does resolution mean

What does resolution mean How is resolution connected to ppi and dpi units

  Differentiate between a bitmap image and a vector image

Differentiate between a bitmap image and a vector image Explain the following terms

  Essential elements of a design pattern

configuration of an Iterator pattern, patterns could be used in a Library System, Singleton, Template, Decorator, Façade,What does Alexander means by the following declaration "But it is impossible to form anything which has the temperament of natu..

  Framework of user interface design

design of user interfaces, natural mapping, GUI applications, web page design different to designing for printed media, risks exposed in this "phone as individual proxy" approach, interaction designers of ubicomp applications, Storyboards are usual..

  What are the factors affecting picture composition

Define picture composition What are the factors affecting picture composition. Elaborate on each factor Describe the basic lines present in a composition

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