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
Aleonysh [2.5K]
1 year ago
8

A cashier distributes change using the maximum number of five dollar bills, followed by one dollar bills. For example, 19 yields

3 fives and 4 ones. Write a single statement that assigns the number of one dollar bills to variable numOnes, given amountToChange. Hint: Use the % operand.
Sample program:
#include
int main(void) {
int amountToChange = 0;
int numFives = 0;
int numOnes = 0;
amountToChange = 19;
numFives = amountToChange / 5;

printf("numFives: %d\n", numFives);
printf("numOnes: %d\n", numOnes);
return 0;
Computers and Technology
1 answer:
posledela1 year ago
6 0

Answer:

The correct program to this question as follows:

Program:

//header file

#include <stdio.h> //include header file for using basic function

int main() //defining main method

{

int amountToChange=19,numFives,numOnes; //defining variable

numFives = amountToChange/5; //holding Quotient  

numOnes = amountToChange%5; //holding Remainder

printf("numFives: %d\n", numFives); //print value

printf("numOnes: %d\n", numOnes); //print value

return 0;

}

Output:

numFives: 3  

numOnes: 4  

Explanation:

In the above program first, a header file is included then the main method is declared inside the main method three integer variable is defined that are "amountToChange, numFives, and numOnes", in which amountToChange variable a value that is "19" is assigned.

  • Then we use the numFives and the numOnes variable that is used to calculate the number of 5 and 1 , that is available in the amountToChange variable.
  • To check this condition we use (/ and %) operators the / operator is used to hold Quotient value and the % is used to hold Remainder values and after calculation prints its value.

You might be interested in
Which of the following provides a suite of integrated software modules for finance and accounting, human resources, manufacturin
zzz [600]

Answer:

B) ERP systems

Explanation:

ERP which means Enterprise Resource Planning is a software that uses a centralized database, it helps to hasten business processes thereby reducing the use of manual labour. Some of the integrated software modules which it provides are:

*Finance, Accounting.

*Human resource.

*Manufacturing and production.

*Sales and marketing.

The ERP system does not really need the total involvement of a human because it has a database where information stored is used in the daily execution of tasks, it can also be used to measure the productivity and profitability of the business.

6 0
2 years ago
A ______________ deals with the potential for weaknesses within the existing infrastructure to be exploited.
algol [13]

Answer:

Threat assessment

Explanation:

A threat assessment deals with the potential for weaknesses within the existing infrastructure to be exploited.

Threat Assessment is further explained as the practice of determining or ascertaining the credibility and seriousness of a potential threat, and also the probability or chases of the threat will becoming a reality.

Threat assessment is separate to the more established procedure of violence-risk assessment, which seek to forcast an individual's general capacity and tendency to respond to situations violently. Instead, threat assessment aims to interrupt people on a route to commit "predatory or instrumental violence, the type of behavior connected with targeted attacks".

3 0
2 years ago
Read 2 more answers
When using the Python shell and code block, what triggers the interpreter to begin evaluating a block of code
finlep [7]

Answer:

The answer is "A blank line".

Explanation:

The blank line initiates the interpreter to start examining the line of statements whenever the Python shell as well as the code block are used.  

  • It is also known as the line that has nothing but spaces or lines without texts or a line.  
  • It prints an empty sheet,  which leaves its performance with such a blank line.

5 0
1 year ago
A packet analyzer is a program that can enable a hacker to do all of the following EXCEPT ________. Select one: A. assume your i
bonufazy [111]

Answer:

Option (B) is the correct answer of this question.

Explanation:

Packet analyzer is a software application or set of infrastructure capable of unencrypted and recording communication that travels through a virtual system of a computer system.A packet analyzer used to detect network activity is recognized as a broadband monitoring system.

A packet analyzer is a code application that is used for monitoring, intercepting, and recording http requests with the help of a virtual interface.

Other options are incorrect because they are not related to the given scenario.

8 0
2 years ago
When the computer is started, a bootstrap or IPL (Initial Program Load) begins testing the system. Where is this bootstrap progr
aniked [119]

Answer:

The correct answer to the following question will be Option B (ROM).

Explanation:

Bootstrap is the programming which initializes the OS during initialization. The bootstrap loader creates small operator programs that connect and monitor the various computer hardware components.

ROM is Read-only memory, which will be used to hold a computer's start-up commands, also recognized as firmware.

No other method was used to help save system startup. ROM, then, is the right answer.

7 0
1 year ago
Other questions:
  • Which statement regarding dialogues in multiplayer games is true? Dialogues are based only on players’ actions.
    7·2 answers
  • Column, bar, pie, line, and scatter are all types of_____
    9·1 answer
  • If the computer has an encrypted drive, a ____ acquisition is done if the password or passphrase is available. a. passive b. sta
    8·1 answer
  • As you are planning your informative speech on the prevalence of Internet memes in pop culture and you wonder if your audience w
    14·1 answer
  • Given a sorted array of integer, A, with possible duplicate elements. Implement an efficient (sublinear running time complexity)
    12·1 answer
  • This exercise shows why each pivot (in eli1nination by pivoting) must be in a different row. (a) In Example 7, make the third pi
    15·1 answer
  • Suppose two threads execute the following C code concurrently, accessing shared variables a, b, and c: Initialization int a = 4;
    15·1 answer
  • Five friends plan to try a startup. However, they have a limited budget and limited computer infrastructure. How can they avail
    11·1 answer
  • A bank in your town updates its customers’ accounts at the end of each month. The bank offers two types of accounts: savings and
    8·1 answer
  • Computers represent color by combining the sub-colors red, green, and blue (rgb). Each sub-color's value can range from 0 to 255
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!