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
docker41 [41]
3 years ago
8

Write an algorithm that receives a number from the user (you can store the number in a variable called N). Then the algorithm sh

ould separate the digits of the number and print each in a line starting from the number at one’s place, then the number at ten’s place, and so on. Example: if user inputs 329, then the algorithm should produce the following three lines.
9

2

3
Computers and Technology
1 answer:
lbvjy [14]3 years ago
7 0

Answer:

Algorithm:

1. Declare an integer variable N.

2. Read the value N from user.

3.While(N):

 3.1 find r=N%10;

 3.2 print r in new line.

 3.3 Update N as N=N/10.

4.end program.

Implementation in C++.

// header

#include <bits/stdc++.h>

using namespace std;

// main function

int main()

{

// variable

int N;

cout<<"Enter an Integer:";

   cin>>N;

// find the digits of number

   while(N)

   {

       // last digit

       int r=N%10;

       // print last digit

       cout<<r<<endl;

       // update the number

       N=N/10;

}

return 0;

}

Output:

Enter an Integer:329                                        

9                                                          

2                                                          

3

You might be interested in
Which of the following is step 5 of the mail merge process?
slamgirl [31]
I think that the answer is b
8 0
4 years ago
Read 2 more answers
Can you guys give some samples of STEM-related studies?​
anygoal [31]

Answer:

D :)))))

Explanation:

hope this helps

5 0
3 years ago
Read 2 more answers
A system administrator is selecting an operating system for use by the company's research and development team. The team require
ruslelena [56]

Answer:

Linux

Explanation:

Linux is a family of open source operating system and can be easily modified and changed to meet its particular requirements. Linux is one the most used operating systems on servers, mainframe computers and even super computers. Being a free and open source system, it can be modified and distributed for both commercial and non commercial by anyone under the terms of its licence.

6 0
4 years ago
There are two major types of wireless networks that are popular today among users. These networks are Wi-Fi and ____
Viefleur [7K]

Answer:

That would be Bluetooth

Explanation:

As Bluetooth is the most widely used network. It is used to operate many things, such as:

Headphones

Speakers

Remotes

etc.

5 0
3 years ago
To add background colour to the webpage – attribute is used in body tag​
mafiozo [28]

\mathfrak{\huge{\orange{\underline{\underline{AnSwEr:-}}}}}

Actually Welcome to the Concept of the HTML.

The tag that can give background color to the Web pages is :-

1.) <Body> bgcolor = "Orange"

</Body>

3 0
3 years ago
Other questions:
  • What are the possible sources of the information that defines the functional dependencies that hold among the attributes of a re
    15·1 answer
  • Alisha's teacher usually includes lots of comments on student tests to help them understand why their answers were
    8·2 answers
  • The material placed around the ignition device to feed the flame in arson is referred to as
    8·1 answer
  • Write a C++ program that will ask the user for the name of a data file.
    11·1 answer
  • HELP
    13·1 answer
  • Which two tools used for incident detection can be used to detect anomalous behavior, to detect command and control traffic, and
    13·1 answer
  • 4.8 Code Practice: Question 1<br> I need help
    13·1 answer
  • Pls help ASAP I’ll brainlest
    6·1 answer
  • An array similar to a phone book has 1000 names arranged as names [0], names[1]....names[999]. Nancy wants to search a name X in
    15·1 answer
  • Are they going to make season two of Midori Days
    15·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!