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
Harlamova29_29 [7]
2 years ago
13

Assume we are testing a variable is_sunny in a while loop. is_sunny = “n”.

Computers and Technology
1 answer:
zubka84 [21]2 years ago
6 0

Answer:

while(is_sunny=="n")

Explanation:

The loop keeps repeating itself until a certain condition is met.

Here while loop keeps executing until value of is_sunny is not equal to 'n'

When the value of is_sunny is not equal to n then the loop stops.

So lets explain this logic with a chunk of code:

#include <iostream> //to use input output functions

using namespace std; //to identify objects like cin cout

int main() {  //start of main function

  string is_sunny = "n"; //value of is_sunny is set to n

  cout<<"Enter value of is_sunny: "; // prompts user to enter value of is_sunny

  cin>>is_sunny; // reads value of is_sunny from user

  while(is_sunny=="n") // keeps iterating until value of is_sunny is not equal to n

  {   cout<<"keep executing until is_sunny is not equal to n"<<endl;//display this message with each iteration

      cout<<"Enter value of is_sunny: "; //keeps prompting to enter is_sunny

      cin>>is_sunny;   } } //keeps reading value of is_sunny from user

Now if the user keeps entering "n" as value of is_sunny then the loop keeps repeating. When the user enters any string other than n then the loop breaks. The output of the program is attached.

You might be interested in
What is a tag in an HTML document?
Llana [10]

Answer: HTML is considered as the Lingua franca of the net that is a simple mark up language used for the purpose of web publishing for creating text and images. This can be viewed by any of the member and can be used within any browser. There is no need of special software for creating HTML pages and moreover the learning of HTML is pretty easy.

Explanation: If you need more help go follow me at dr.darrien

- thank you

3 0
3 years ago
Read 2 more answers
Write 9 words but each word starting with a letter of computer? After your finished the first letter of each of your words shoul
oksian1 [2.3K]

Answer:

<h2>C- rippled</h2><h2>O- utstanding</h2><h2>M- agical</h2><h2>P- eace</h2><h2>U- npredictable</h2><h2>T- riumph</h2><h2>E - xcellent</h2><h2>R- obust</h2>

Explanation:

<h3><u>Acronym</u>- a word that composes of long words that start with its initial letter.</h3><h3>Example: OTG (on the go)</h3>

\tt{ \green{P} \orange{s} \red{y} \blue{x} \pink{c} \purple{h} \green{i} e}

7 0
3 years ago
Read 2 more answers
While designing a website, a(n) ____ allows you to identify the specific amount of space used on a particular page before it con
Aleks [24]
The answer would be A: wireframe, im pretty sure...

Hope this helped!! :)

8 0
3 years ago
Read 2 more answers
1. In which generation were semiconductor memories used for the first time:
Llana [10]

1: D. Third Generation

2: C. 10

4 0
3 years ago
Jennifer has written a business report. What should be her last step before she submits the story for publication?
Montano1993 [528]
Revising and editing because it makes the report look sharp and business like.
5 0
3 years ago
Read 2 more answers
Other questions:
  • WHAT SHOULD YOU DO IF AN ONCOMING CAR AT NIGHT APPROACHES WITH ITS HIGH-BEAMS ON?
    6·1 answer
  • What are the uses of joystick​
    13·1 answer
  • What would you recommend for data segregation if using cloud software
    12·2 answers
  • Georgenotfound??? question mark??
    15·2 answers
  • What is the unit used to describe the intensity of sound?
    5·1 answer
  • Alice is working on a web page to attract the maximum number of people to join her cause. She wants to inform people about the b
    12·1 answer
  • ¿Que es la energía? (una sola respuesta es la correcta)
    11·1 answer
  • How many people are in Siver, on the game Valorant?
    14·1 answer
  • You will need to convert the following binary numbers to hexadecimal. Table 1 contains 16 problems. The first one is completed f
    7·1 answer
  • When conducting memory and recall tests, some people make an effort to normalize memories by not reporting extreme cases. this l
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!