Computer Science, asked by rishitp08, 3 months ago

c coding language want solution of you know then only answer or wrong answer will be reported​

Attachments:

Answers

Answered by dhanamvijay2002
1

Answer:

C program for first 20 odd numbers.

#include<stdio.h>

#include<conio.h>

void main()

{

int n=20,i;

clrscr();

for(i=1;i<=n;i++)

{

if((i%2)!=0)

{

printf("%d\n",i);

}

}

getch();

}

C program for first 20 even numbers.

#include<stdio.h>

#include<conio.h>

void main()

{

int n=20,i;

clrscr();

printf("

for(i=1;i<=n;i++)

{

if((i%2)==0)

{

printf("%d\n",i);

}

}

getch();

}

Similar questions