#include<stdio.h>
int main()
{
int n,i;
printf("enter the number \n");
scanf("%d",&n);
printf("The odd number series is:\n");
for(i=1;i<=n;i=i+2)
{
printf("%d\t",i);
}
}
Output:
int main()
{
int n,i;
printf("enter the number \n");
scanf("%d",&n);
printf("The odd number series is:\n");
for(i=1;i<=n;i=i+2)
{
printf("%d\t",i);
}
}
Output:
Comments
Post a Comment