Write a program to swap two input integer values without using a temporary variable and display the swapped values. The input values have to be obtained using a scanf statement. (In other words, the entire program must require only these two input values to swap them. A third variables must not be declared or used.) [Hint: Try adding the two input integer values and store it as one of the given input values. From there, you can proceed.]

Respuesta :

Answer:

The program is designed using C programming language

Explanation:

#include <stdio.h>

int main () {

printf("Enter the first number here ");

scanf("%f", num1);

printf("Enter the second number here ");

scanf("%f", num2);

num1 = num1 + num2 ;

num1 = num2 - num1 ;

num2 = num2 - num1;

printf("The swapped number num is %f\n", num1);

  printf("The second swapped is %f", num2);

  return(0);

}