बिजनेस मार्केटिंग का लो कॉस्ट फंडा , अपने मोबाइल से ऑटो sms भेजकर मार्केटिंग करे विजिट करे http://autotextsms.com/ बिजनेस मार्केटिंग का लो कॉस्ट फंडा http://autotextsms.com/

Search This Blog

Translate

c program for swapping two numbers using call by value

c program for swapping two numbers using call by value,c program for swapping two numbers without using temporary variable,c program for swapping two numbers without using a third variable,c program for swapping two numbers using pointers,program for prime number in c,c program for fibonacci series,c program for factorial,c program for swapping of two numbers using function

C Program for swapping two  numbers without using third variable


void main()
{
    int a,b;
    clrscr();
    printf("\nEnter the first number=");
    scanf("%d",&a);
    printf("\nEnter the second number=");
    scanf("%d",&b);
    printf("\n\n*** Original value ***\nFirst value is=%d\n\nSecond value is=%d",a,b);
    a=a+b;
    b=a-b;
    a=a-b;
    printf("\n\n*** After swapping ***\n\nFirst value is=%d\n\nSecond value is=%d",a,b);
    getch();
}


C Program for swapping two  numbers without using third variable

c program for swapping two numbers using call by value,c program for swapping two numbers without using temporary variable,c program for swapping two numbers without using a third variable,c program for swapping two numbers using pointers,program for prime number in c,c program for fibonacci series,c program for factorial,c program for swapping of two numbers using function

C Program example List