How the memory management in vectors are being done. What
happens when the heap memory is full, and how do you handle it ?
No Answer is Posted For this Question
Be the First to Post Answer
Write a program to find the reverse Fibonacci series starting from N.
Do we have to use initialization list in spite of the assignment in constructors?
We all know that a const variable needs to be initialized at the time of declaration. Then how come the program given below runs properly even when we have not initialized p?
throw Can constructors exceptions?
Explain how we implement exception handling in c++?
What is command line arguments in C++? What are its uses? Where we have to use this?
What are the defining traits of an object-oriented language?
What is the difference between a baller and a reference in C++?
How would perform Pattern Matching in C++?
What is struct c++?
1)#include <iostream.h> int main() { int *a, *savea, i; savea = a = (int *) malloc(4 * sizeof(int)); for (i=0; i<4; i++) *a++ = 10 * i; for (i=0; i<4; i++) { printf("%d\n", *savea); savea += sizeof(int); } return 0; } 2)#include <iostream.h> int main() { int *a, *savea, i; savea = a = (int *) malloc(4 * sizeof(int)); for (i=0; i<4; i++) *a++ = 10 * i; for (i=0; i<4; i++) { printf("%d\n", *savea); savea ++; } return 0; } The output of this two programs will be different why?
What is buffering in c++?