main()
{
char *ptr = "Ramco Systems";
(*ptr)++;
printf("%s\n",ptr);
ptr++;
printf("%s\n",ptr);
}
Find the Outputs?
Answer Posted / dhakchin moorthy.p
first printf stmt prints Ramco Systems
the error is in line ptr++;here u r trying to increment the
address holding by the pointer,pointer var may lost the
starting address.
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What is a char in c?
What is keyword in c?
Where define directive used?
What is void c?
Explain the use of bit fieild.
Who developed c language and when?
difference between native and cross compilers
Explain spaghetti programming?
How do you determine the length of a string value that was stored in a variable?
Explain how can you avoid including a header more than once?
What are high level languages like C and FORTRAN also known as?
How does free() know explain how much memory to release?
develop algorithms to add polynomials (i) in one variable
What is the value of c?
What is the difference between c &c++?