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
postnew [5]
3 years ago
11

Read an integer from keyboard and then print the result of the sum obtained by adding the entered integer to the integer formed

by reversing the order of the digits. (For example: entered number = 123. Sum = 123+321 = 444)
Computers and Technology
1 answer:
Stels [109]3 years ago
3 0

Answer:

Following are the program in C++ language

#include <iostream> // header file

using namespace std; //  namespace std;

int main() // main function

{

int number,n1,rem; // variable declaration

int sum,sum1=0;// variable declaration

cout<<"Enter the number :";

cin>>number;// Read the number

n1=number; // initialized the value of number with the n1

while(n1>0) // iteating the  while loop

{

   rem=n1%10; // finding the reminder

   sum1=10*sum1+rem;  // storing the sum

   n1=n1/10;

}

sum=sum1+number; // calculate the sum

cout<<"The sum is:"<<sum; // Display sum

   return 0;

}

Output:

Enter the number :123

The sum is:444

Explanation:

Following are the Description of the Program

  • Read the value of "number" in the "number" variable of int type .
  • Initialized the value of "number" in the "n1' variable.
  • Iterating the while loop until the n1>0.
  • In this loop we reverse the number in the "sum1" variable
  • Finally print the sum in the "sum" variable

You might be interested in
Why do networks need standards?
svetoff [14.1K]

Answer:

4. Standards are what guarantee that the different pieces of network are configured to communicate with one another

Explanation:

Networking standards ensure the interoperability of networking technologies by defining the rules of communication among networked devices. Networking standards exist to help ensure products of different vendors are able to work together in a network without risk of incompatibility

Hope it will help you...

3 0
3 years ago
IN MICROSOFT EXCEL YOU CAN UES FOMULA TO DIVIDE OR MULTIPLY WHAT IS THE CORRECT FORMULA TO CALCULATE 4*6
nexus9112 [7]

You actually have the correct answer. An excel formula starts with = so your answer would be =4*6

8 0
3 years ago
How is an operating system like a translator?
emmasim [6.3K]

Answer:

Operating systems work like translators because they are able to take software and hardware, and put it all together to work in a way that is readable and usable for the consumer.

5 0
3 years ago
Each of the following are advanced strategies you may use to help you conduct a search on the Internet except _____. using a wil
malfutka [58]

i cant see anything tho theres nothing there

4 0
3 years ago
Read 2 more answers
How do i convert videos on the computer
mr Goodwill [35]

Answer:

An online tool or software.

Explanation:

Video conversion can be done using an online tool and software. If you choose to convert your videos by using an online tool, open any online tool and paste the link of the video or upload a video file from your computer, select the format you want and then click convert. Conversion takes a few seconds, and once the conversion is done, you can download the audio file. And if you choose to convert your videos by using the software, you have to download software, install it in your personal computer, and use it for conversion. In this process of transformation, you have to upload a video file from your computer. And if you do not need the output file format, some software can choose the setup automatically.

5 0
3 years ago
Other questions:
  • Henry bought a new card for capturing television on his computer. When he finished going through the packaging, though, he found
    5·1 answer
  • Laura has identified the job she wants, the skills needed for the position, and the areas she needs to improve in order to get i
    10·1 answer
  • Which osi layer is responsible for combining bits into bytes and bytes into frames?
    8·1 answer
  • What is one course of action available in every problem solving process?
    9·2 answers
  • When a user utilizes another computer to communicate with a third party, with the result that the third party cannot recognize t
    8·1 answer
  • What was the first fully computer animated feature film?
    13·1 answer
  • What is the usual price of smartphone apps?
    8·2 answers
  • "True or False? Software designers use layering and other techniques to organize large software systems."
    13·1 answer
  • Which type of information should never be given out on social media?
    5·2 answers
  • The owner creator of a folder/file object has complete access to the object even when no user or group is assigned any access to
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!