#include<stdio.h>
int main()
{
    int a,b,c;
    printf("Enter the first number\n");
    scanf("%d",&a);
    printf("Enter the second number\n");
    scanf("%d",&b);
    printf("\n before swapping a=%d b=%d\n",a,b);
    c=a;
    a=b;
    b=c;
    printf("\n after swapping a=%d b=%d\n",a,b);
}
Output:
 
 
Comments
Post a Comment