jamomoja88 jamomoja88
  • 02-01-2022
  • Computers and Technology
contestada

What is the C++ program to display 3 6 9 12 15​

Respuesta :

YBS20
YBS20 YBS20
  • 02-01-2022

Answer:

#include <iostream>

using namespace std;

int main()

{

   

   int n = 15;

   

   for(int i=3; i<=n; i=i+3){

       cout<<i;

       cout<<" ";

   }

   return 0;

}

Explanation:

Used for loop to calculate number and display it. for start with 3(int i=3), increment by 3(i=i+3) and stop when 15 came (i<=n where n is 15).

Answer Link

Otras preguntas

Percy is watching people order frozen yogurt at a yogurt shop. He counts 25 out of 100 people who order raspberry. This means that his experimental probability
Which of the following items is not a temporary difference? A. Vacation pay accrued for tax purposes in a prior period is deducted in the current periodB. Tax
What might geneticists learn about genes by studying rna.
Solve the radical equation.
20 POINTS !!! What is one way that New Deal policies reformed economic institutions affected by the economy? The government stabilized and stimulated the econom
Need help with question number 55
The Permian Period lasted from 299 Ma to 251 Ma. This means that the Permian Period lasted _______ years. No choices to choose from!
1800 doubles in value every 7 years
what is the general terms of the sequence 4, 7, 12, 19​
the graph shows the relationship between the volume of a rectangular prism and the volume of a square pyramid with an identical base and height what is the slop