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

Answer Posted / 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       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of turbo c++?

767


What is java and c++?

881


How can I learn c++ easily?

836


Differences between private, protected and public and give examples.

771


Where must the declaration of a friend function appear?

737


Why was c++ created?

781


Will rust take over c++?

793


What is the difference between global int and static int declaration?

627


How to declare an array of pointers to integer?

806


What is c++ similar to?

845


Is nan a c++?

864


What are separators in c++?

821


What is the difference between the functions memmove() and memcpy()?

870


Which software is used to run c++ program?

728


Is java the same as c++?

741