Question
In C++, a base class pointer holds the address of a derived class object. The base class declares a non-virtual member function that the derived class redefines (not overrides) with the same signature. When this function is called through the base class pointer, which version executes?
More C Programming Questions
- Consider the recursive function: int fact(int n) { if (n == 0) return 1; return n * fact(n-1); } How many total function calls (including the ver...
- Which Java keyword is used to inherit a class?
- Which of the following statements is correct for Python lists?
- What is the output of the following C code? int x=5, y=0; if (x>0 || y++) { } printf("%d", y);
- Consider the following C structure on a typical 32-bit system, where int is 4 bytes, char is 1 byte, and the compiler applies default structure padding for...
- What is a key difference between the malloc() and calloc() functions in C?
- What will be printed by the following C code ? int x = 13, y = 6; printf("%d", (x & y) + (x | y) - (x ^ y));
- In Python, what does len() function do?
- Consider the following C code: int a[]={10,20,30,40}; int *p=a; What is the value of *(p+2)?
- What is the output of the following C code? struct Point { int x, y; }; struct Point p1 = {3,4}; struct Point *ptr = &p1; ptr->x += ptr->y; ptr->y = p...
Hey! Ask a query
Please enter email id
The email must be a valid email address.
Please enter Mobile Number
Please enter valid Mobile Number
Please enter your Doubt
Think You're Ready for RBI Grade B?
RBI Grade B 2026 Phase 1 Memory Based Paper
- 200 Questions with Detailed Solutions
- Section-wise Coverage (GA, English, Quant & Reasoning)