write a program to swap two variables a=5 , b= 10 without
using third variable
Answer Posted / shafi.shaik
main()
{
int a,b;
clrscr();
printf("enter a, b Value");
scanf("%d%d",&a,&b);
printf("\n%d",a);
printf("\n%d",b);
b=b-a;
a=a+b;
b=a-b;
printf("\n%d",a);
printf("\n%d",b);
getch();
}
Is This Answer Correct ? | 1 Yes | 3 No |
Post New Answer View All Answers
Explain about the constants which help in debugging?
How many types of operators are there in c?
How do you print only part of a string?
How can I manipulate strings of multibyte characters?
Given below are three different ways to print the character for ASCII code 88. Which is the correct way1) char c = 88; cout << c << " ";2) cout.put(88);3) cout << char(88) << " "; a) 1 b) 2 c) 3 d) constant
Explain bitwise shift operators?
write a program that reads lines(using getline), converts each line to an integer using atoi, and computes the average of all the numbers read. also compute the standard deviation.
What are the different types of constants?
Explain indirection?
What is a constant and types of constants in c?
When can you use a pointer with a function?
What is a memory leak? How to avoid it?
What do you understand by friend-functions? How are they used?
What are conditional operators in C?
hai iam working in sap sd module for one year and working in lumax ind ltd in desp department but my problem is i have done m.b.a in hr/marketing and working sap sd there is any combination it. can you give right solution of my problem. and what can i do?