PROGRAM TO ADD TWO NUMBERS USING POINTERS

/*PROGRAM TO ADD TWO NUMBERS USING POINTERS*/
#include<stdio.h>
#include<conio.h>
void main()
{
int a,b,c=0;
int *m,*n;
clrscr();
printf(“Enter any two numbers: “);
scanf(“%d%d”,&a,&b);
m=&a;
n=&b;
c=(*m)+(*n);
printf(“Addition of two numbers is: %d”,c);
getch();
}

Leave a Reply

Your email address will not be published. Required fields are marked *