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
Oksi-84 [34.3K]
3 years ago
15

Write a do-while loop that continues to prompt a user to enter a number less than 100, until the entered number is actually less

than 100. End each prompt with a newline. Ex: For the user input 123, 395, 25, the expected output is:Enter a number (<100): Enter a number (<100): Enter a number (<100): Your number < 100 is: 25c++ #include using namespace std;int main() { int userInput = 0;do cout << "Your number < 100 is: " << userInput << endl; return 0;}
Computers and Technology
1 answer:
Ad libitum [116K]3 years ago
6 0

Answer:

#include<iostream>//library inclusion

using namespace std;

int main()

{

int userInput;

do//start of do while loop

{

 cout << "Enter a number less than a 100" << endl;

 cin >> userInput;

 if (userInput < 100) //condition

 {

  cout << "YOu entered less than a hundred: " << userInput << endl;

 }

 else

 {

  cout << "your number is greater than 100" << endl;

 }

} while (userInput > 100);//condition for do while

return 0;//termination of int main

}

Explanation:

The program has been commented for you. The do-while loop enters the first loop regardless of the condition. Then after the first iteration, it checks for the condition. If the condition is being met, it will iterate through, again. Otherwise it will break out of the loop and land on the "return 0;" line. Which also happens to be the termination of the program in this case. The if-else condition is used for the user to see when prompted.

You might be interested in
In codd's model of a relational database, data is stored in a(n) _____, which maintains information about a(
Dmitry [639]
<span>Which is not a component of a database that describes how data is stored?</span>
5 0
3 years ago
A client reports the client has been experiencing increased stress at work. The client has been managing the stress by drinking
katovenus [111]

Answer:

d. The client has no adaptive coping mechanisms.

Explanation:

The reduction of anxiety felt by the clients is reduced by the Clients in either the functional ways or dysfunctional ways.

The first thing done by the nurse was to find out the techniques used by the client in past and help the client to enhance and identify those most beneficial strategies .The next step is done by the client and the nurse to find out the maladaptive strategies such as alcohol use,social withdrawal and swap them with adaptive strategies which are suitable for the client's cultural,personal and spiritual values.

The nurse should not suggest the client to give up coping mechanism without offering other mechanism even if the client is having the maladaptive strategies.

4 0
3 years ago
Each wireless network has its own name to identify it, known as service set identity. true false
Dominik [7]
True. The acronym for service set identity is SSID, which you've likely saw before. And like you say, it's simply the unique name given to a wireless network so that we are able to identify what network we are connecting to.
8 0
3 years ago
To share a server folder, access the ____ tab in the folder properties dialog box and click the share button (or from the window
anygoal [31]
Oh lord I have no idea :/ I suck at this yeah idk
5 0
3 years ago
Blank text has a darker apperance than normal texts
sammy [17]
That's cool, I guess. What was the question?
4 0
3 years ago
Other questions:
  • Identify at least three body language messages that project a positive attitude?
    15·1 answer
  • You are an administrator for contoso.com. you have two servers called server1 and server2 that run windows server 2012 and have
    9·1 answer
  • (50 points) Write a program arrays1.cthat checks if two integer arrays are different by one and only one elementwhen compared el
    5·1 answer
  • A technician with a PC is using multiple applications while connected to the Internet. How is the PC able to keep track of the d
    8·2 answers
  • Matching: match each step with its correct sequence number. This question tests whether you know the order in which a CPU perfor
    14·1 answer
  • You are trying to log in to your old computer, and can't remember the password. You sit for hours making random guesses... I'm s
    10·1 answer
  • Michael needs to ensure that those items that are automatically archived are still easily accessible within Outlook. Which optio
    7·2 answers
  • Which of these is a negative effect of computer technology's role in creating
    9·1 answer
  • 1. Write the full forms of the following.
    8·2 answers
  • Double clicking the top right corner of a document will
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!