Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Is there any difference between dlearations int* x and int
*x? If so tell me the difference?

Answer Posted / foo

The difference is that in the first case the space is after
the * and in the second case the space is before.

Functionally there is no difference.

Arguably int* x is slightly worse since (as other answers
demonstrate) people can misinterpret "int* i, j" as
declaring two pointers-to-int where "int *i, j" is perhaps a
bit clearer.

Practically, you should adopt whatever style is required by
wherever you work or whomever you work with.

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do we need constructors in c++?

1064


What are the advantages of using a pointer?

1023


What is c++ library?

997


What are shallow and deep copy?

1045


How are pointers type-cast?

1064


Why c++ is created?

954


Define what is constructor?

1005


Define pre-condition and post-condition to a member function in c++?

1090


What is the difference between global variables and static varables?

1072


What language is a dll written in?

968


Should I learn c or c++ first?

1073


What is the main purpose of overloading operators?

1059


What is setf in c++?

1048


What is c++ array?

1036


Why null pointer is used?

999