Answer :
#include<stdio.h> //header file contains the function,decleraction and macro defination of key words used in code.
int main ()
{
int num1,num2,swap; //adressing the variables
num1=20; //assining the values for variables
num2=10; //assining the values for variables
printf("Before Swaining Num1 = %d and Num2=%d\n",num1,num2); //output
swap=num1; /*swaping the numbers by using third variable.
swaping means interchanging the value of variables*/
num1=num2;
num2=swap;
printf("After Swaining Num1 = %d and Num2=%d\n",num1,num2); //output
}
Output :
0 Comments