1.
In C, the NULL pointer is used __________________.
2.
An array of n numbers is given, where n is an even number. The maximum, as well as the minimum, of these n numbers needs to be determined. Which of the following is true about the comparisons needed?
3.
In C, the minimum number of comparisons that are required to determine whether an integer appears more than n/2 times in a sorted array of integers is __________________.
4.
What is the output of the following C code snippet:
int main() {
    extern int a;
    printf("%d
", a);
    return 0;
}

int a = 20;
5.
What is the output of the following C code snippet:
int main() {
    static int a = 20;
    printf("%d
%d
", a++, ++a);

}
6.
What is the error in the following C code:

#include
int f(int a) {
    a > 20 ?
        return (10): return (20);
}
int main() {
    int f(int);
    int b;
    b = f(20);
    printf("%d
", b);
    return 0;
}
7.
What is the output of the following C code snippet:

#include
int main() {
    char * p = NULL;
    char * q = 0;
    if (p)
        printf(" p ");
    else
        printf("nullp");
    if (q)
        printf("q
");
    else
        printf(" nullq
");
}
8.
What is the output of the following C code snippet:
#include <stdio.h>

int main()
{
int h[4] = {1, 2, 3, 4};
int *a = h;
printf("%d %d", a, h);
}
9.
What is the output of the following C code:
#include <stdio.h>
int main()
{
int *ptr = (int *)100;
ptr = ptr + 2;
printf("%u", ptr);
}
10.
What is the output of the following C code:
#include <stdio.h>

int main()
{
int *p = (int *)20;
int *q = (int *)30;
printf("%d", q - p);
}