Program to add two numbers using pointers


#include<stdio.h>
#include<conio.h>
main()
{
int *ptr1,*ptr2;
int add;
printf("enter two numbers");
scanf("%d%d",ptr1,ptr2);
add=*ptr1+*ptr2;
printf("\nthe sum i8s %d",add);
getch();
}

0 comments:

Post a Comment