Sunday 11 December 2011

Write a program to print this series:-1 3 5 7 9 11 13 15 17 19 21 23 25 ………… 99 with while loop in c

#include
#include
main()
{
int i=1;
clrscr();
while(i<=100)
{
printf("%d\t",i);
i=i+2;
}
getch();
}

OUTPUT

1 3 5 7 9 11 13 15 17 19 21 23 25 ………… 99

No comments:

Post a Comment