Teaching Rajasthan Basic Computer Instructor 2021 Mock Test Programming and Data Structure Programming in C
What is the expected output for the given c program?
#include
int main()
{
int a, b;
scanf("%d %d", &a, &b);
a=a+b;
b=a-b;
a=a-b;
printf("\nAfter swap a=%d b=%d",a,b);
return 0;
}
1
swap the numbers
2
reverse number
3
Sum of digits
4
Sum and subtract the digits