Author Question: How many times will the following loop display "Looping!"? for (int i = 20; i > 0; i--) cout (Read 22 times)

EAugust

  • Hero Member
  • *****
  • Posts: 550
How many times will the following loop display "Looping!"?
for (int i = 20; i > 0; i--)
     cout << "Looping!" << endl;

20
19
21
◦ an infinite number of times



Related Topics

Need homework help now?

Ask unlimited questions for free

Ask a Question
 

Did you know?

Dogs have been used in studies to detect various cancers in human subjects. They have been trained to sniff breath samples from humans that were collected by having them breathe into special tubes. These people included 55 lung cancer patients, 31 breast cancer patients, and 83 cancer-free patients. The dogs detected 54 of the 55 lung cancer patients as having cancer, detected 28 of the 31 breast cancer patients, and gave only three false-positive results (detecting cancer in people who didn't have it).

Did you know?

Drugs are in development that may cure asthma and hay fever once and for all. They target leukotrienes, which are known to cause tightening of the air passages in the lungs and increase mucus productions in nasal passages.

Did you know?

In 1864, the first barbiturate (barbituric acid) was synthesized.

Did you know?

Adolescents often feel clumsy during puberty because during this time of development, their hands and feet grow faster than their arms and legs do. The body is therefore out of proportion. One out of five adolescents actually experiences growing pains during this period.

Did you know?

Hypertension is a silent killer because it is deadly and has no significant early symptoms. The danger from hypertension is the extra load on the heart, which can lead to hypertensive heart disease and kidney damage. This occurs without any major symptoms until the high blood pressure becomes extreme. Regular blood pressure checks are an important method of catching hypertension before it can kill you.

For a complete list of videos, visit our video library