Difference between const char* p and char const* p?



Difference between const char* p and char const* p?..

Answer / hrpynux@gmail.com

There is no difference between const char *p and char const *p as both are pointer to a const char and position of '*'(asterik) is also same. 2. char *const ptr : This is a constant pointer to non-constant character. You cannot change the pointer p, but can change the value pointed by ptr.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C++ General Interview Questions

What is the default width for ouputting a long integer using the insertion operator?

0 Answers  


What are literals in C++?

0 Answers   Wipro,


What is the best free c++ compiler for windows?

0 Answers  


In the derived class, which data member of the base class are visible?

0 Answers  


Comment on c++ standard exceptions?

0 Answers  


give me an example for testing a program showing the test path .show how the test is important and complex.

0 Answers   TCS,


what is C++ exceptional handling?

0 Answers  


What is a reference in C++?

1 Answers  


Can class objects be passed as function arguments?

0 Answers   HCL,


What is public, protected, private in c++?

0 Answers  


What is the v-ptr?

0 Answers  


What are templates? where we should use it?

2 Answers   Alcatel,


Categories