1answer.
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
Rainbow [258]
3 years ago
7

Write a program with total change amount as an integer input that outputs the change using the fewest coins, one coin type per l

ine. The coin types are dollars, quarters, dimes, nickels, and pennies. Use singular and plural coin names as appropriate, like 1 penny vs. 2 pennies.
Computers and Technology
1 answer:
alexandr1967 [171]3 years ago
7 0

Answer:

a=input("Amount in pennies")

b=int(a)

dollars=0

dimes= 0

quarters=0

nickels=0

pennies = 0

dollars = int(b/100)

b= b- dollars *100

quarters=int(b/25)

b=b-quarters*25

dimes = int(b/10)

b = b -dimes*10

nickels=int(b/5)

b=b - nickels * 5

pennies = b

print(dollars)

print(dimes)

print(nickels)

print(pennies)

Explanation:

The required program is in answer section. Note, the amount is entered in pennies.

You might be interested in
You are auditing a client's network and have gained physical access to a workstation. To prevent any security software from dete
Llana [10]

Answer:

OphCrack LiveCD.

Explanation:

The user examines that server of a client, as well as requires complete control of such a system. To avoid recognizing its invasion by certain security programs, he wants to select a LiveCD which can break Operating System's credentials,  and he would have been using OphCrack LiveCD because it used to crack the credential of the Windows user.

So, the following are the reason by which the answer is correct according to the scenario.

3 0
3 years ago
State one technique for overcoming external fragmentation in dynamic partitioning. Why is this technique of overcoming external
prisoha [69]

Compaction often gives solutions to the issues regarding external fragmentation.

One technique for overcoming external fragmentation in dynamic partitioning is

Compaction.

The reason why this technique of overcoming external fragmentation may be inefficient is because:

  • External fragmentation may need a lot of compaction and it is an expensive operation.

  • The use of contiguous allocation is often hard to fit processes into memory and also it is so difficult to grow or shrink the amount of memory allocated to a process.

  • Compaction only takes place when relocation is dynamic, and this also is expensive.

Compaction often shuffle memory notes or contents and then put or pile them up all in free memory and in one large block.

External fragmentation takes place when free memory is removed into small blocks.

Learn more from

brainly.com/question/23636593

4 0
2 years ago
Write a function called getRowTotal. This function should accept a two-dimensional int array as its first parameter (the array h
garik1379 [7]

Answer:

The solution is implemented using C++

int getRowTotal(int a[][5], int row) {

  int sum = 0;

  for(int i =0;i<5;i++)

  {

      sum += a[row][i];

  }

  return sum;

}

Explanation:

This defines the getRow function and the parameters are arr (the 2 d array) and row and integer variable

int getRowTotal(int arr[][5], int row) {

This defines and initializes sum to 0

  int sum = 0;

This iterates through the row and adds the row items

<em>   for(int i =0;i<5;i++)    { </em>

<em>       sum += arr[row][i]; </em>

<em>   } </em>

This returns the calculated sum

  return sum;

}

8 0
3 years ago
Select the correct answer. What is the final step of the object-oriented design process?
Vikentia [17]
D. Writing the methods of the classes
6 0
2 years ago
When is blue for when the instance in which the directory of compulsion in the air!
KATRIN_1 [288]
I think it’s what the other person said
7 0
3 years ago
Other questions:
  • Suppose an array with six rows and eight columns is stored in row major order starting at address 20 (base 10). If each entry in
    8·1 answer
  • Soft skills are similar to personality traits like being compassionate, having patience, and working well in groups.
    10·2 answers
  • Write a C++ program that prompt the user to enter three points (x1, y1), (x2, y2), (x3,y3) of a triangle and
    14·1 answer
  • Katherine wants to open a bank account that allowed her to perform frequent transactions without being charged a penalty and she
    14·1 answer
  • Python
    5·1 answer
  • Write a C++ program that takes two numbers from the command line and perform and arithmetic operations with them. Additionally y
    11·1 answer
  • What can i use to erase data off computer and what name of it and steps
    9·1 answer
  • What, if anything, is returned by the method call rearrange ("apple")?
    8·1 answer
  • What can be changed when a style is modified?
    5·2 answers
  • Choose a common cloud-based application from the lesson.(Infrastructure as a service, Software as a service, Platform as a servi
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!