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
Masja [62]
3 years ago
14

Given that two int variables, total and amount, have been declared, write a sequence of statements that: initializes total to 0

reads three values into amount, one at a time. After each value is read in to amount, it is added to the value in total (that is, total is incremented by the value in amount). Instructor Notes: Do not use any looping. Just use three cin statements and three calculations.
Computers and Technology
1 answer:
artcher [175]3 years ago
6 0

Answer:

Following are the program in C++ language :

#include <iostream> // header file

using namespace std; // using namespace

int main() // main method

{

   int amount,total=0; // two int variable declaration

   cout<<" enter amount:";

   cin>>amount; // read input amount first time

   total=total+amount; // first calculation

   cout<<" enter amount:";

   cin>>amount; //read input amount second time

   total=total+amount;// second calculation

   cout<<" enter amount:";

   cin>>amount;// read input amount third time

   total=total+amount;// third calculation

   cout<<"total:"<<total; // display total

  return 0;

}

Output:

enter amount:12

enter amount:12

enter amount:12

total:36

Explanation:

Following are the explanation of program which is mention above

  • Declared the two variable total and amount of int type .
  • Initialize the variable total to "0".
  • Read the 3 input in "amount" variable in one by one by using cin function and adding their value to the "total "variable .
  • Finally display the total.
You might be interested in
Which tcp/ip troubleshooting command should you use to determine whether a client and server are communicating with each other?
sesenic [268]
The answer is <span>The ping command.   The </span><span>tcp/ip troubleshooting command you should  use to determine whether a client and server are communicating with each other is The ping command.  </span><span>The </span>ping command<span> is used to verify that a device can communicate with another on a network.</span>
5 0
3 years ago
System inputs and outputs are produced at the end of the: A. systems analysis phase of the SDLC. B. systems planning and selecti
Savatey [412]

Answer: A) systems analysis phase of the SDLC.

Explanation:

In accordance with system development life cycle(SDLC) , analysis phase is the stage where all the requirement and materials for the system are collected and ordered.The requirements are in the form of input and output which are extracted and documented to provide clear vision of outcome.

  • Other options are incorrect because design phase is for designing the format ans structure of system through input components. Planning and selection stage is making scheme through opting correct requirement for system.
  • Implementation and operation phase is the stage of implementing the components on system structure to make them perform their respective tasks. Logic modelling level is defining inputs , components, outputs in logical manner so that they provide desired result operating.
  • Thus, the correct operation is option(A).

5 0
3 years ago
Convert A4B from hexadecimal to binary. Show your work.
Rama09 [41]

Answer:

The answer is A4B₁₆ =  2635₁₀ =  101001001011₂

Explanation:

To convert from hexadecimal base system to binary base system, first you can do an intermediate conversion from hexadecimal to decimal using this formula:

where position of the x₁ is the rightmost digit of the number and the equivalents hexadecimal numbers to decimal:

  • A = 10.
  • B = 11.
  • C = 12.
  • D = 13.
  • E = 14.
  • F = 15.

A4B₁₆ = A*16²+4*16¹+B*16⁰ = 2560 + 64 + 11 = 2635₁₀

Now, you have the number transformed from hexadecimal to decimal. To convert the decimal number 2635 to binary: Divide the number repeatedly by 2, keeping track of each remainder, until we get a quotient that is equal to 0:

2635 ÷ 2 = 1317 + 1;

1317 ÷ 2 = 658 + 1;

658 ÷ 2 = 329 + 0;

329 ÷ 2 = 164 + 1;

164 ÷ 2 = 82 + 0;

82 ÷ 2 = 41 + 0;

41 ÷ 2 = 20 + 1;

20 ÷ 2 = 10 + 0;

10 ÷ 2 = 5 + 0;

5 ÷ 2 = 2 + 1;

2 ÷ 2 = 1 + 0;

1 ÷ 2 = 0 + 1;

Now, construct the integer part base 2 representation, by taking the remainders starting from the bottom of the list:

2635₁₀ =  101001001011₂

3 0
3 years ago
Universal Containers sells its products online using a system built on Force Sites. The orders are captured and processed in Sal
sveta [45]

Answer:

Use Outbound Messages to send customer data from Salesforce to the marketing system.

Use a middleware tool to pull customer data from Salesforce and push it to the marketing system on a daily basis

Use Apex callout to send customer data from Salesforce to the marketing system

Explanation:

The above points illustrates a mechanism for moving cutomer data to the marketing system efficiently.

3 0
4 years ago
Any information that is processed by and sent out from a computer or other electronic device is considered __________.
wel

Answer:

Your answer will be output.

Hope this helps!

3 0
3 years ago
Read 2 more answers
Other questions:
  • Into which of these files would you paste copied information to create an integrated document? A. Mailing list B. Source C. Data
    13·2 answers
  • What do you remember about the difference between Canadian and US dollar (which one is greater)? Also, explain which online tool
    6·1 answer
  • What is a shot sequence
    10·1 answer
  • What are personal skills? A manner of individual style How a person manages and expresses oneself One's ability to excel at spor
    13·2 answers
  • What is equivalent to 5(3x-7)
    13·2 answers
  • How to write a self-analysis essay
    5·1 answer
  • The algorithm ____ is used to find the elements in one range of elements that do not appear in another range of elements.
    5·1 answer
  • What is the internet?
    6·2 answers
  • Send me the answers<br>​
    15·1 answer
  • Instructions: Write a program that calculates the amount of ingredients needed for various flavors of cheesecake.
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!