Program to display Odd numbers between 1-100 Using for loop in C++
Program to display Odd numbers between 1-100 Using for loop
It is simple program which can display Odd numbers between 1-100 even you can change the value and get more output of numbers.
Program :-
#include<iostream.h>
void main ()
{
int i;
for(i=1;i<=100;i=i+2)
cout<<i<<"\t";
}
Output :-
1 3 5 7 9 ............ 99
It is simple program which can display Odd numbers between 1-100 even you can change the value and get more output of numbers.
Program :-
#include<iostream.h>
void main ()
{
int i;
for(i=1;i<=100;i=i+2)
cout<<i<<"\t";
}
Output :-
1 3 5 7 9 ............ 99
Comments
Post a Comment