Program to Print all Even Numbers in an Array using Pointers.

#include<stdio.h> #include<conio.h>  main() { int a[10],n,i; printf(“enter size of the array”); scanf(“%d”, ...



#include<stdio.h>
#include<conio.h> 
main()
{
int a[10],n,i;
printf(“enter size of the array”);
scanf(“%d”, &n);
printf(“enter the elements”);
for(i=0; i
scanf(“%d”, a[i]);
printf(“even numbers are \n”);
for (i=0; i
{
if (*(a+i)%2==0)
{
printf(“%d\n”, *(a+i));
}
}
getch();
}

Related

PERFORM ARITHMETIC OPERATIONS

#include<stdio.h> #include<conio.h> main() {             int a,b, res;          &...

FACTORIAL OF A NUMBER USING RECRSION AND WITHOUT RECURSION

#include<stdio.h> #include<conio.h> int fact(int n); int factrec(int n); main() {      int n,ch,y;      clrscr();     ...

Program for SWAPING OF 2 NUMBERS USING CALL BY VALUE ,CALL BY REFERENCE

#include<stdio.h> #include<conio.h> swap(int x,int y); swap(int *x,int *y); main() {           int a,b,ch;     ...

Post a Comment

emo-but-icon
:noprob:
:smile:
:shy:
:trope:
:sneered:
:happy:
:escort:
:rapt:
:love:
:heart:
:angry:
:hate:
:sad:
:sigh:
:disappointed:
:cry:
:fear:
:surprise:
:unbelieve:
:shit:
:like:
:dislike:
:clap:
:cuff:
:fist:
:ok:
:file:
:link:
:place:
:contact:

item