//Swap two variables with call by reference
#include<stdio.h>
#include<math.h>
void main(){
int a,b,c,*p,*q;
p=&a;
q=&b;
printf("ENTER ANY TWO NUMBER =\n");
scanf("%d",&a);
scanf("%d",&b);
printf("the value of a= %d\n",a);
printf("The value of b=%d\n",b);
//printf("%d\n",*p);
//printf("%d\n",*q);
c=*p;
*p=*q;
*q=c;
printf("THE REVERSE VALUE a= %d \n b= %d = ",a,b);
}
To embed this project on your website, copy the following code and paste it into your website's HTML: