WRITE A SIMPLE C++ PROGRAM TO SWAP TWO NOS WITHOUT USING TEMP
Answers were Sorted based on User's Feedback
Answer / vinodhini r
main()
{
int a,b;
scanf("%d %d",&a,&b);
a=a+b;
b=a-b;
a=a-b;
printf("%d %d",a,b);
}
| Is This Answer Correct ? | 26 Yes | 2 No |
What is polymorphism what is it for and how is it used?
Difference ways of Polymorphism?
Explain virtual inheritance?
What is abstraction in oop?
c++ is a purely oop concept?
In which Scenario you will go for Interface or Abstract Class?
1 Answers InfoAxon Technologies,
What are the fields of vtable
difference between static and non-static variables?
Is enum a class?
tel me oops defination in single line
is java purely oop Language?
49 Answers HCL, Infosys, TCS,
where is memory for struct allocated? where is memory for class-object allocated? I replied for struct in stack and for class-object in heap. THen he asked if class has struct member variable what happens.class on heap and what about struct in that class? couldnt ans :( :-?