answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
fgiga
4 days ago
15

The Coins class was created to hold all your loose change, kind of like a piggy bank! For this exercise, you are going to simula

te starting a bank with a specific number of coins, then adding to your piggy bank to bring your total to $2.12. What you need to do: Create a Coins object that initially has 4 quarters, 3 dimes, 2 nickels, and 1 penny. After you create the initial object, print out the total, then add coins to your bank until you have a total of 15 coins totaling 2.12. You will need to figure out which combination gets you to the correct total with the correct number of coins! When you are finished, call the method to print the bank count then the bank total to verify that you got the correct values.
Computers and Technology
1 answer:
Amiraneli [955]4 days ago
8 0

Answer:

Coins c1 = new Coins (4, 3, 2, 1);

c1.bankValue();

c1.addQuarter();

c1.addQuarter();

c1.addDime();

c1.addDime();

c1.addPenny();

c1.bankCount();

c1.bankValue();

Explanation:

You might be interested in
A router has a valid operating system and a configuration file stored in nvram. the configuration file contains an enable secret
oksian1 [849]
The mode displayed is user EXEC mode. This mode is utilized for configuring, observing, and testing system processes. Typically, user EXEC commands allow connection to remote devices, temporary modification of terminal line settings, conducting basic tests, and displaying system details. This mode is commonly accessed by standard system admins, while privileged EXEC mode is reserved for the root administrator. Switch between these two levels using the enable and disable commands. A valid password is required to access the user-level EXEC command line.
8 0
15 days ago
Widget Corp. wants to shift its list of inventory to a cloud so that its different branches can access it easily. The company ne
oksian1 [849]
The most suitable cloud option for Widget Corp, which requires a solution that is both cost-effective and does not risk exposing critical applications and data externally, is a hybrid cloud.
5 0
23 days ago
When long labels are required, which of these commands can you use to improve readability of a worksheet?
maria [967]
I think it's text wrapping! I hope this assists you.
6 0
11 days ago
Read 2 more answers
Write a class named Taxicab that has three **private** data members: one that holds the current x-coordinate, one that holds the
amid [867]

Response:

Refer to the explanation

Details:

class Taxicab():

def __init__(self, x, y):

self.x_coordinate = x

self.y_coordinate = y

self.odometer = 0

def get_x_coord(self):

return self.x_coordinate

def get_y_coord(self):

return self.y_coordinate

def get_odometer(self):

return self.odometer

def move_x(self, distance):

self.x_coordinate += distance

# increase the odometer with the absolute distance

self.odometer += abs(distance)

def move_y(self, distance):

self.y_coordinate += distance

# increase odometer with the absolute distance

self.odometer += abs(distance)

cab = Taxicab(5,-8)

cab.move_x(3)

cab.move_y(-4)

cab.move_x(-1)

print(cab.odometer) # will output 8 3+4+1 = 8

7 0
1 month ago
Represent decimal number 8620 in (a) BCD, (b) excess-3 code, (c)2421 code, and (d) as a binary number
maria [967]

The decimal number 8620 can be expressed in the following ways:

a = 1000 0110 0010 0000

b = 1011 1001 0101 0011

c = 1110 1100 0010 0000

d = 10000110101100

I hope these representations answer your question and prove useful.

4 0
1 month ago
Other questions:
  • Assume a program requires the execution of 50 x 106 FP instructions, 110 x 106 INT instructions, 80 x 106 L/S instructions, and
    9·1 answer
  • How to code 2.9.5: Four colored triangles {Code HS}
    10·1 answer
  • Susan is assisting a web designer to create a promotional web page on eco-friendly classroom designs. She uses color combination
    5·1 answer
  • An author is preparing to send their book to a publisher as an email attachment. The file on their computer is 1000 bytes. When
    6·1 answer
  • Some early computers protected the operating system by placing it in a memory partition that could not be modified by either the
    5·1 answer
  • On the planet Sigma, robots excavate chunks of a very precious cristaline. These chunks can be divided into smaller part only on
    15·1 answer
  • One form of Intrusion Detection System (IDS) starts operation by generating an alert for every action. Over time, the administra
    5·1 answer
  • In a survey of 7200 T.V. viewers, 40% said they watch network news programs. Find the margin of error for this survey if we want
    6·1 answer
  • The ______ is the information center that drivers need to refer to when they're NOT scanning the road.
    7·1 answer
  • hard disk drive has 16 platters, 8192 cylinders, and 256 4KB sectors per track. The storage capacity of this disk drive is at mo
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!