What will be the output of the following “C” program?
![]()
Practice Control Instructions – What will be the output of the following “C” program?
int main ()
{
unsigned int i;
for (i = 10; i >= 0; i--)
printf ("%d", i);
} ![]()
Practice Control Instructions – What will be the output of the following “C” program?
int main ()
{
unsigned int i;
for (i = 10; i >= 0; i--)
printf ("%d", i);
} ![]()
Practice Arrays – *A + 1 – *A + 3
![]()
Practice Functions – What will be the output of the following “C” program?
int main ()
{
int i = 2, j = 3, k = 1;
swap (i, j);
printf ("%d %d", i, j);
}
swap (int i, int j)
{
int temp;
temp = i; i = j; j = temp;
} ![]()
Practice Basic Concept – What will be the output of the following “C” program?
int main()
{
int i = 20;
printf ("%x", i);
return 0;
} ![]()
Practice Variable Number of Arguments – int *i;
float *f;
char *c;
Which are the valid castings?
![]()
Practice Pointers – p and q are pointers to the same type of data items.
Which of these are valid?
(i) *(p+q)
(ii) *(p-q)
(iii) *p – *q
![]()
Practice Declarations and Initializations – Which is the valid declaration?
![]()
Practice Memory Allocation – x = malloc (y).
Which of the following statements is correct.
![]()
Practice Arrays – &A[5] – &A[1]?
![]()
Practice Expressions – What is the value of the following expression?
i = 1;
i << 1 % 2 ![]()
Practice Control Instructions – int a = 0, b = 2;
if (a = 0)
b = 0;
else
b *= 10;
What is the value of b?
![]()
Practice Structures, Unions, Enums – The following statement is
“The size of a struct is always equal to the sum of the sizes of its members”
![]()
Practice Basic Concept – C allows
![]()
Practice Expressions – What is the value of the following expression?
i = 1;
i = (i <<= 1 % 2)
![]()
Practice Control Instructions – int x = 2, y = 2, z = 1;
What is the value of x after the following statmements?
if (x = y%2)
z = x;
else
z=y;