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
Gekata [30.6K]
3 years ago
9

Write a C++ program that allows the user to enter double values. Display one of two messages: "The first number you entered is l

arger", "The second number you entered is larger". Save file as LargerorNot.cpp
Computers and Technology
1 answer:
VikaD [51]3 years ago
7 0

Answer:

Following are the program in c++

#include <iostream> // header file

using namespace std; // namespace

int main() // main function

{

double a,b; // variable declaration

cout<<"Enter the first number and second number : \n";

cin>>a>>b; // input the number

if(a>b) // check first number greater than second number

{

cout<<"The first number you entered is larger";

}

else

{

cout<<"The second number you entered is larger";

}

return 0;

}

Output:

Enter the first number and second number :

45.5

687.8

The second number you entered is larger

Explanation:

In this program we have declared two variable i.e a and b of double type. After that check the condition if(a>b) if this condition is true then display  the message "The first number you entered is larger " otherwise display the message  "The second number you entered is larger".

You might be interested in
The main events of the civil war and reconstruction
rosijanka [135]
While many still debate the ultimate causes of the Civil War<span>, Pulitzer Prize-winning author James McPherson writes that, "The </span>Civil War started<span> because of uncompromising differences between the free and slave states over the power of the national government to prohibit slavery in the territories that had not yet become </span>
3 0
4 years ago
Who is the father of computer?​
bagirrra123 [75]

Answer:

The first automatic digital computer has been designed by the English mathematician and inventor Charles Babbage. Babbage developed the Analytical Engine Plans for the mid-1830s.

Explanation:

  • Babbage has developed the concept of a digital, programmable computer and was a mathematician, philosopher, inventor, and mechanical engineer.
  • Some regard Babbage as a "computer father"
  • The inventing of its first mechanical computer, the difference engine, is attributable to Babbage, which eventually resulted in more complex electronic designs, although Babbage's Analytical Engine is the main source of ideas for modern computers. He was described as the "prime" among the numerous polymaths of his century by his varied work in another field.
7 0
3 years ago
At the county fair, prizes are awat rded to the five heaviest cows. More than 2000 cows are entered, and their records are store
Sergeu [11.5K]

Answer:

B

Explanation:

selection sort for each pass sorts one element in right place . so we can stop it after 5 passes as we need only 5 heaviest cows info.

Answer is B

6 0
3 years ago
Which part of the cpu accepts data?
V125BC [204]

The answer is the Processor register.

5 0
3 years ago
Think about your favorite technology item - phone, game, smartTV, etc. - Write about how your favorite technology item has impac
grandymaker [24]

Answer:

that is about you you put what are the good and the bads of nechnoilogy

4 0
3 years ago
Other questions:
  • Create a different version of the program that: Takes a 3-digit number and generates a 6-digit number with the 3-digit number re
    14·1 answer
  • ​What file system below does not support encryption, file based compression, and disk quotas, but does support extremely large v
    10·1 answer
  • In a(n) ________ either one condition or some other condition must be met in order for an event to take place.
    11·1 answer
  • For your biology class, you will be giving a presentation of the findings of a plant growth experiment. Which application is bes
    7·1 answer
  • What are the missing letters _A_TO_ ( 6 letters) a type of computer.
    13·2 answers
  • Please help I don’t know
    5·1 answer
  • Which of the following statements about content-based filtering is TRUE?
    9·1 answer
  • Which programming scenario would most likely involve this array block?<br><br>SOMEONE PLEASE HELPPP​
    9·1 answer
  • A ____________________ machine is used to gather or arrange in their proper sequence.
    9·1 answer
  • A _____ model is one that is automatically adjusted based on changing relationships among variables.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!