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

Which operations are permitted on pointers?

1043


what are the types of Member Functions?

1177


What do you mean by enumerated data type?

1105


How a new operator differs from the operator new?

1186


What is recursion?

2381


What is iomanip c++?

1117


Mention the ways in which parameterized can be invoked. Give an example of each.

1115


Does improper inheritance have a potential to wreck a project?

1217


What's the hardest coding language?

1068


Describe the role of the c++ in the tradeoff of safety vs. Usability?

1272


State the difference between pre and post increment/decrement operations.

1151


Out of fgets() and gets() which function is safe to use?

1195


What is an orthogonal base class in c++?

1214


Array base access faster or pointer base access is faster?

2361


What are static variables?

1192