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 abstraction in c++ with example?

0 Answers  


What are inline functions? What is the syntax for defining an inline function?

0 Answers  


Is c++ the most powerful language?

0 Answers  


What is the C-style character string?

0 Answers  


How would you implement a substr() function that extracts a sub string from a given string?

0 Answers  


How can you create a virtual copy constructor?

0 Answers  


write a programme to get a character and thier ASCII value

0 Answers  


Can we run c program in turbo c++?

0 Answers  


What are the new features that iso/ansi c++ has added to original c++ specifications?

0 Answers  


What is the use of main function in c++?

0 Answers  


when can we use copy constructor?

6 Answers   HP,


How can I disable the "echo" feature?

0 Answers  


Categories