Swapping without Third Variable

#include<stdio.h>
int main()
{
    int a=5,b=10;
    a=b+a;
    b=a-b;
    a=a-b;
    printf("a= %d  b=  %d",a,b);
    return 0;
}

Share this

Related Posts

Dear User,

Thank you for your comment. Hope you like this blog. Kindly share us on Social Media so others can be updated.

-Chief Administrative Officer.