Why do we need templates?
No Answer is Posted For this Question
Be the First to Post Answer
class Alpha { public: char data[10000]; Alpha(); ~Alpha(); }; class Beta { public: Beta() { n = 0; } void FillData(Alpha a); private: int n; }; How do you make the above sample code more efficient? a) If possible, make the constructor for Beta private to reduce the overhead of public constructors. b) Change the return type in FillData to int to negate the implicit return conversion from "int" to "void". c) Make the destructor for Alpha virtual. d) Make the constructor for Alpha virtual. e) Pass a const reference to Alpha in FillData
Is c++ the hardest language?
What is the maximum combined length of command line arguments including the space between adjacent arguments?
What parameter does the constructor to an ofstream object take?
How many characters are recognized by ANSI C++?
What is the latest version on c++?
What is the v-ptr?
What are the total number of lines written by you in C/C++? What is the most complicated or valuable program written in C/C++?
What is class syntax c++?
What is std namespace in c++?
What is scope resolution operator in c++ with example?
How to implement is-a and has-a class relationships?