If you had the following code: int x = 23; int *y; y = &x;
The instruction y++; does what?
Answers were Sorted based on User's Feedback
Answer / 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 |
Answer / anu
Then y will point to next memory location.
If we are using (*y)++ will increment value to 24.
| Is This Answer Correct ? | 4 Yes | 5 No |
What are the 3 levels of programming languages?
Is turbo c++ free?
What are all predefined data types in c++?
Write a program to show polymorphism in C++?
Describe Trees using C++ with an example.
What are signs of manipulation?
Can you pass a vector to a function?
what is the diff b/n c and c++ a. dynamic scoping b. nested switching c. declaration of variables in any code block d. separation of compilation and linking
What C++ libraries are you proficient with?
Is it possible for the objects to read and write themselves?
Explain function overloading and operator overloading.
Will the inline function be compiled as the inline function always? Justify.