Is there any difference between dlearations int* x and int
*x? If so tell me the difference?
Answer Posted / debendra nath tiwary
there is no difference between them here.
but difference comes how we use them.
(int*) can be used for typecasting.
(int *x) is used for declaration purpose. here x is declared as pointer variable.
even if declare like (int* x) is valid but not a formal way to
to declare pointer variable.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Explain linked list using c++ with an example?
What are c++ templates used for?
What is data types c++?
Declare a class vehicle and make it an abstract data type.
What is iomanip c++?
What are c++ variables?
What is helper in c++?
Eplain extern keyword?
If horse and bird inherit virtual public from animal, do their constructors initialize the animal constructor? If pegasus inherits from both horse and bird, how does it initialize animal’s constructor?
What is pointer in c++ with example?
What is the use of object in c++?
Who invented turbo c++?
Explain the difference between using macro and inline functions?
What is lazy initialization in c++?
What do you mean by funtion prototype?