CODING:
#include <stdio.h>
void main()
{
int a,b;
printf("Enter a and b");
scanf("%d",a);
scanf("%d",b);
printf("Before Swapping a=%d,b=%d"a,b);
a=a+b;
b=a-b;
a=a-b;
printf("After Swapping a=%d,b=%d"a,b);
}
#include <stdio.h>
void main()
{
int a,b;
printf("Enter a and b");
scanf("%d",a);
scanf("%d",b);
printf("Before Swapping a=%d,b=%d"a,b);
a=a+b;
b=a-b;
a=a-b;
printf("After Swapping a=%d,b=%d"a,b);
}
Comments
Post a Comment