given the code segment below
void main()
{
cout<<"my no. is";
}
question is how can we get the output hai aravind my no. is
99999999999 without editig the main().
Answer Posted / pankaj rathor
#include <iostream>
using namespace std;
class dummy
{
public:
dummy()
{
cout<<"Hai Arvind ";
}
~dummy()
{
cout<<" 99999999999";
}
};
dummy obj;
int main()
{
cout<<"my no. is";
return 0;
}
| Is This Answer Correct ? | 15 Yes | 2 No |
Post New Answer View All Answers
Which software is best for c++ programming?
Arrange Doubly linked list in the ascending order of its integral value and replace integer 5 with 7?
Can I learn c++ without c?
How do I download c++?
Explain terminate() and unexpected() function?
What is difference between array and vector in c++?
Explain how we implement exception handling in c++?
Is c++ fully object oriented?
What is the difference between a template and a macro?
What are the 4 types of library?
Which one between if-else and switch is more efficient?
Which bit wise operator is suitable for checking whether a particular bit is on or off?
Why is c++ not purely object oriented?
How would you use the functions sin(), pow(), sqrt()?
write a function signature with various number of parameters.