a C prog to swap 2 no.s without using variables just an
array?
Answer Posted / baidyanath bisoyi
void main()
{
int a,b;
printf("enter the two numbers\n");
scanf("%d%d",&a,&b);
printf("a=%d\n b=%d\n",a,b);
a=a+b-(b=a);
printf("a=%d\n b=%d\n",a,b);
getch();
}
| Is This Answer Correct ? | 4 Yes | 3 No |
Post New Answer View All Answers
What are data structures in c and how to use them?
HOW TO SOLVE A NUMERICAL OF LRU IN OS ??????
What does 3 mean in texting?
Which programming language is best for getting job 2020?
How reliable are floating-point comparisons?
Is exit(status) truly equivalent to returning the same status from main?
What does void main return?
What is the use of static variable in c?
Can a pointer be null?
Is it cc or c in a letter?
What are preprocessor directives in c?
How can you find the exact size of a data type in c?
What is getch () for?
Explain what is the heap?
how much salary u want ? why u join in our company? your domain is core sector why u prefer software ?