What is the difference between const int *ptr and int const
*ptr???
Answers were Sorted based on User's Feedback
a) const int *ptr and
b) int const *ptr
Both actually mean the same...
Read from Right to left:
for(a):-> ptr is a pointer to an integer Constant and
for(b):-> ptr is a pointer to a constant integer...
..............
int *const ptr----------> ptr is a constant pointer to an
integer...
Is This Answer Correct ? | 95 Yes | 26 No |
Answer / abdul sami
'const int* ptr' means the value whose address is being
held by ptr is constant and cant be changed while
'int const *ptr' means the pointer cant be changed like it
cant be incremented or decremented although you can change
the date pointed to by ptr.
Is This Answer Correct ? | 41 Yes | 57 No |
difference between structure and union.
what are three tenets of object orinted Systems?Why they call like that ? Please answer me. Advance thanks.
What are properties in oop?
which is best institute to learn c,c++ in ameerpet hyderabad
Precompilation ?
What is the output of the following code: int v() { int m=0; return m++; } int main() { cout<<v(); } 1) 1 2) 0 3) Code cannot compile
Have you ever used threads?
Why is abstraction used?
what is the definition of incapsulation
What is the difference between procedural programming and oops?
What are functions in oop?
Tell us about yourself.
47 Answers ABB, Amazon, Fidelity, Flextronics, Franklin Templeton, HCL, Hexaware, IBM, Impetus, Infosys, Reliance, Rofous, Silgate, Sutherland, TCS, Thomson Reuters, Virtusa, Wipro,