class CTest
{
public:
void someMethod()
{
int nCount = 0;
cout << "This is some method --> " << nCount;
}
};
int main()
{
CTest *pctest;
pctest->someMethod();
return 0;
}
It will executes the someMethod() and displays the value
too. how is it possible with our creating memory for the
class . i think iam not creating object for the class.
Thanks in Advance...
Prakash
No Answer is Posted For this Question
Be the First to Post Answer
What is inheritance write a program to show use of inheritance?
Write a c++ program to display pass and fail for three student using static member function
What do you mean by Encapsulation?
Write on signed and unsigned integers and give three (3) examples each
You attempt to query the data base with this command: SELECT name, salary FROM employee WHERE salary=(SELECT salary FROM employee WHERE last name='Wagner' OR dept no=233) Choose most appropriate option from the following: 1)Sub-queries are not allowed in the where clause. 2)a multiple row sub-query used with a single row comparison operator. 3)a single row query is used with a multiple row comparison operator.
How is the using() pattern useful? What is IDisposable? How does it support deterministic finalization?
What is deep and shalow copy?
define oops with class and object
IS IT NECESSARY TO INITIALIZE VARIABLE? WHAT IF THE INSTANCE VARIABLE IS DECLARED final ? IS IT NECESSARY TO INITIALIZE THE final VARIABLE AT THE TIME OF THEIR DECLARATION?
what are the disadvantages of C++?
25 Answers ATS, Infosys, UNI, Wipro,
What are the 3 principles of oop?
Why polymorphism is used in oops?