//what is wrong with the programme??
#include<iostream.h>
template <class first>
class dd
{
first i;
public:
void set();
void print();
};
void dd< first>:: set()
{
cin>>i;
}
void dd< first>::print()
{
cout<<"\n"<<i;
}
void main()
{
dd <char>g;
g.set();
g.print();
}
Answer / prakash
template<class first> void dd<first>::set()
{
cin>>i;
}
template<class first> void dd<first>::print()
{
cout<<"\n"<<i;
}
| Is This Answer Correct ? | 1 Yes | 0 No |
1.what are two type of classe members called? 2.what is data hiding and data encapsulation? 3.how do you make a class member visible aouside its class? 4.what is the default visibility of a class data member? 5.what are the advantages of oop over the structured programing?
what is the difference between class and object?
What is Iteration Hierarchy? What is what is Object behavioral concept?
all about pointers
what is overloading and overriding?
Can you inherit a private class?
What is overloading in oop?
what is opps?why it is use in programming language?
difference between class and object
10 Answers Chandan, IBM, Magic Soft,
what is oops
what does exactly the linker do?
How to calculate the age from the date of birth by using the program?