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
diamong [38]
3 years ago
6

In a C++ program, one and two are double variables and input values are 10.5 and 30.6. After the statement cin >> one >

> two; executes, ____.
Computers and Technology
1 answer:
SSSSS [86.1K]3 years ago
6 0

Answer:

variable one stores 10.5 and two stores 30.6

Explanation:

In c++ language, the cout keyword is used to write to the standard output. The input from the user is taken by using the cin keyword.

For the input from the user, a variable need is declared first.

datatype variable_name;

The input can be taken one at a time as shown.

cin >> variable_name;

The input for more than one variable can be taken in a single line as given by the syntax below.

1. First, two variables are declared.

datatype variable_name1, variable_name2;

2. Both input is taken simultaneously as shown.

cin >> variable_name1, variable_name2;

For the given scenario, two double variables are declared as below.

double one, two;

The question mentions input values for the two double variables as 10.5 and 30.6.

3. The given scenario takes both the values as input at the same time, in a single line as shown below.

cin >> one >> two;

4. After this statement, both the values entered by the user are accepted.

The values should be separated by space.

First value is stored in the variable one.

Second value is stored in the variable two.

5. The user enters the values as follows.

10.5 30.6

6. The value 10.5 is stored in variable one.

7. The value 30.6 is stored in variable two.

The c++ program to implement the above is given below.

#include <iostream>

using namespace std;

int main() {

   double one, two;      

   cout << " Enter two decimal values " << endl;

   cin >> one >> two;

   cout << " The input values are " << endl;

   cout << " one : " << one << " \t " << " two : " << two << endl;

   return 0;

}

OUTPUT

Enter two decimal values  

10.5 30.6

The input values are  

one : 10    two : 530.6

You might be interested in
The use of technology to observe a user's actions often without the user's knowledge is known as:
Margaret [11]

Answer:

C

Explanation:

Computer surveillance refers to spying that allows the viewer to gain access of all activity on the given computer.

5 0
2 years ago
Which device is used to direct the flow of data on a computer network?
alexgriva [62]

Answer: router

Explanation:

a router directs flow of information

3 0
2 years ago
A ________ database state is one in which all data integrity constraints are satisfied
beks73 [17]
A consistent database base is one in which all data integrity constraints are satisfied.
8 0
3 years ago
Read 2 more answers
Assume you are working for the laboratory that is developing the control system for the LISAsatellites. Your job is to develop a
ladessa [460]

<u>Answer:</u>

?????????????/

<u>Explanation:</u>

???????????//

8 0
3 years ago
In cell G6, use the appropriate lookup and reference function to retrieve the rental rate from the named range RentalRates. The
lora16 [44]

=VLOOKUP($A6,RentalRates,2,0) is the lookup for this.

<u>Explanation:</u>

Utilize the LOOKUP capacity to look into an incentive in a one-section or one-push go, and recover an incentive from a similar situation in another segment or one-push go. The query work has two structures, vector and cluster. This article depicts the vector structure.

In computer science, a lookup table is a cluster that replaces run time calculation with a more straightforward exhibit ordering activity. The investment funds as far as handling time can be critical, since recovering an incentive from memory is regularly quicker than experiencing a "costly" calculation or information/yield activity.

5 0
3 years ago
Other questions:
  • 5. In Access, data is stored in a _______ once a form is completed. A. cell B. page C. record D. form
    13·1 answer
  • . How is a form used?
    10·1 answer
  • What is an optical storage device?
    7·2 answers
  • What are the five types of alignment in Word?
    12·2 answers
  • Int a=10 int b=20<br> A=b<br> The new values for a and b are
    11·2 answers
  • What will be the values of ans, x, and y after the following statements are executed? int ans = 35, x = 50, y =50; if ( x &gt;=
    7·2 answers
  • I need to change the subject before they get onto me. I am only revealing info today if you are a friend.
    5·1 answer
  • Consider the code below. When you run this program, what is the output if the temperature is 77.3 degrees Fahrenheit?
    6·1 answer
  • A customer is looking for a storage archival solution for 1,000 TB of data. The customer requires that the solution be durable a
    9·1 answer
  • What is the outcome when a floating-point number is divided by zero?
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!