The operation for adding an entry to a stack is traditionally called:
The main purpose of declaring a union.
The correct way for a structure in C to contain a pointer to itself is
Consider the declaration :
struct sample
{
unsigned int a;
unsigned int b;
};
struct sample v;
The size of v.b is
Consider the program segment given below. (The italicized numbers represent program line numbers) :
1. #include
2. int y;
3. void main()
4. {
5. int x,*px,**ppx;void f1(int *);
6. x = 10;
7. y = 1000;
8. px = &x;
9. ppx = &px;
10. f1(px);
11. printf(“%d”,*px);
12. }
13. void f1(int *p)
14. {
15. *p = 20;
16. printf(“%d”,*p);
17. }
The printf() at line 11 prints the value:
#include
void prg(int);
main()
{
int a=10,j=3,i=2;
prg(a);
a*=( i + j );
printf(“%d”,a);
}
void prg(x)
{
int x;
int k=2;
x*=k;
return (x);
}
What is the output of this program?
This pointer for any class internally declared as
What is the output of the following code?
#include
void main()
{
int arr[]={0,1,2,3,4,5,6};
int i,*ptr;
for(ptr=arr+4,i =0; i<=4; i++)
printf("\n%d",ptr[-i]);
}
#include
void main()
{
int I=10,*p=&I,**q=&p;
printf(“%u”,***(&(*(&Q))));
}
What is the output of this program?
How can I dynamically allocate a two-dimensional array?