#include<stdio.h>
#include<conio.h>
int main()
{
int a[4][4]={{5,7,5,9},
{4,6,3,1},
{2,9,0,6}};
int *p;
int (*q)[4];
p=(int*)a;
q=a;
printf("\n%u%u",p,q);
p++;
q++;
printf("\n%u%u",p,q);
getch();
return 0;
}

what is the meaning of this program?

Answer Posted / sanjay bhosale

Assuming base address is 1000.
And integer requires 4byte of memory.

First printf will give 1000 and 1000
while second printf will give 1004 and 1016.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How are structure passing and returning implemented?

673


The statement, int(*x[]) () what does in indicate?

767


What are the types of assignment statements?

727


Explain how do you override a defined macro?

676


In a switch statement, what will happen if a break statement is omitted?

700






what are the program that using a two dimensional array that list the odd numbers and even numbers separately in a given 10 inputs values

1353


How will you delete a node in DLL?

765


How can you allocate arrays or structures bigger than 64K?

780


Why is c still so popular?

705


What are bitwise shift operators in c programming?

729


What is a buffer in c?

670


What are the similarities between c and c++?

690


What happens if you free a pointer twice?

698


What are the advantages of Macro over function?

1424


Write a code to remove duplicates in a string.

728