Can we have a non static member function in a base class to
be override in derived with static modifier?
Answer Posted / srinivas
sorry i have given the reverse once . Even the reverse
works fine..
class sample
{
public:
static void get(){cout<<"this is base class
function:"<<endl;}
void put(){cout<<"this is a put function of base
class :"<<endl;}
};
class sample1:public sample
{
public:
static void put(){cout<<"this is a derived class
function:"<<endl;}
};
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
How many types of namespaces available in version4?
What is winforms c#?
What is the default value of decimal in c#?
What is a delegate how is it type safe?
How can encapsulation be achieved?
What is deferred execution?
Which control cannot be placed in mdi?
How does substring work in c#?
What is a int in c#?
What is the syntax for calling an overloaded constructor within a constructor (this() and constructorname() does not compile)?
What is oledbconnection c#?
What is the difference between the debug class and trace class? Documentation looks the same.
What is difference between string and stringbuffer in c#?
What is int32 in c#?
Define sealed classes in c#?