main()
{
int ptr[] = {1,2,23,6,5,6};
printf("%d",&ptr[3]-&ptr[0]);
}
Answer Posted / baba
Ans: 12
The expression in printf evaluates the difference of the memory addresses of ptr[3] and ptr[0]
| Is This Answer Correct ? | 5 Yes | 10 No |
Post New Answer View All Answers
What is structure in c explain with example?
Explain the array representation of a binary tree in C.
disply the following menu 1.Disply 2.Copy 3.Append; as per the menu do the file operations 4.Exit
Explain how do you override a defined macro?
What are the benefits of c language?
How variables are declared in c?
What is methods in c?
why to assign a pointer to null sometimes??how can a pointer we declare get assigned with a garbage value by default???
How reliable are floating-point comparisons?
can we have joblib in a proc ?
How can I write data files which can be read on other machines with different word size, byte order, or floating point formats?
Why void main is used in c?
int i=3; this declaration tells the C compiler to a) reserve space in memory to hold the integer value b) associate the name i with this memory location c) store the value 3 at this location d) all the above
What does volatile do?
Explain void pointer?