char* ptr = "Rahul";
*ptr++;
printf("%s",ptr);
What will be the output
Answer Posted / amit
Ans: ahul
Reason:
Initially character pointer ptr pointed to the first character
of Rahul..when we increase it by increament operator it increase one byte.because size of character is one bye..
now it point to a..
we print from here
therefore we got above answer
so
| Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
Prepare me a program for the animation of train
What is polymorphism give a real life example?
What is inheritance and how many types of inheritance?
What is destructor oops?
any one please tell me the purpose of operator overloading
write a program that takes input in digits and display the result in words from 1 to 1000
Why is oop better than procedural?
What is encapsulation with real life example?
What is difference between data abstraction and encapsulation?
What is constructor in oop?
INSTANCE FIELDS DECLARED private ARE ACCESSIBLE BY THE METHODS ONLY.CAN WE CHANGE THE private FIELD OF AN OBJECT IN A METHOD OF SOME OTHER OBJECT OF THE SAME CLASS?
How Do you Code Composition and Aggregation in C++ ?
Why is encapsulation used?
Why can't we have instance(stack) of a class as a member of the same class like eg.Class A{A obj;} as we can have self refential pointer
What is the example of polymorphism?