C++ for statement loop with cout statement

Description

C++ for statement loop with cout statement

#include <iostream>
using namespace std;
int main()    // all expressions inside for's parentheses
{
   int count;/*  w  w  w .j  a  va2  s .c  o m*/
   for (count = 2; count <= 20; cout << count << "  ", count = count + 2);
   return 0;
}



PreviousNext

Related