When should we use multiple inheritance?
No Answer is Posted For this Question
Be the First to Post Answer
Find out the bug in this code,because of that this code will not compile....... #include <iostream> #include <new> #include <cstring> using namespace std; class balance { double cur_bal; char name[80]; public: balance(double n, char *s) { cur_bal = n; strcpy(name, s); } ~balance() { cout << "Destructing "; cout << name << "\n"; } void set(double n, char *s) { cur_bal = n; strcpy(name, s); } void get_bal(double &n, char *s) { n = cur_bal; strcpy(s, name); } }; int main() { balance *p; char s[80]; double n; int i; try { p = new balance [3]; // allocate entire array } catch (bad_alloc xa) { cout << "Allocation Failure\n"; return 1; }
How does a C++ structure differ from a C++ class?
What are friend classes?
What are destructors?
Can you sort a set c++?
What are the two types of comments?
What is the use of namespace std in C++?
Can we remove an element in a single linked list without traversing? Lets suppose the link list is like this 1 2 3 4 5 6 We need to remove 4 from this list (without traversing from beginning) and the final link list shud be 1 2 3 5 6 only thing we know is the pointer to element "4". How can we remove "4" and link "3" to "5"?
How does code-bloating occur in c++?
Copy Linked List using recursive function?
How can a called function determine the number of arguments that have been passed to it?
How do you import payscale data from non SAP to SAP?is it through LSMW or any other way is there?