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...

If you had the following code: int x = 23; int *y; y = &x;
The instruction y++; does what?

Answer Posted / naresh kumar

here Y is integer pointer which is storing address of x.
suppose we assume address of X is 65524. this value will stored in pointer variable Y. int variable is capable of storing 2 bytes of memory. If increment or decrement variable Y, It points to next memory location, i.e 65526.

that means y=65524
y++
65526
y++
65528
this will keep on increasing by 2 bytes.

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the role of copy constructor in copying of thrown objects?

1070


What is a modifier in c++?

1155


Explain the uses oof nested class?

1144


What is a hashmap c++?

1127


Function can be overloaded based on the parameter which is a value or a reference. Explain if the statement is true.

1123


What are maps in c++?

967


What is c++ namespace?

1216


Write about the use of the virtual destructor?

1009


What are files in c++?

1041


Evaluate the following expression as C++ would do :8 * 9 + 2 * 5 a) 82 b) 79 c) 370 d) list

1004


What is the use of namespace std in C++?

1073


How can you quickly find the number of elements stored in a dynamic array?

1054


what do you mean by volatile variable?

1057


How new/delete differs from malloc()/free?

1146


If all is successful, what should main return a) 0 b) 1 c) void

1018