31. 

What will be the output of the program in Turbo C?

#include<stdio.h>

int main()
{
    char str[10] = "India";
    str[6] = "Max";
    printf("%s\n", str);
    return 0;
}

A. India Max
B. Max
C. India
D. Error

32. 

What will be the output of the program ?

#include<stdio.h>

int main()
{
    char str1[] = "Hello";
    char str2[] = "Hello";
    if(str1 == str2)
        printf("Equal\n");
    else
        printf("Unequal\n");
    return 0;
}

A. Equal
B. Unequal
C. Error
D. None of above

33. 

What will be the output of the program ?

#include<stdio.h>

int main()
{
    char t;
    char *p1 = "India", *p2;
    p2=p1;
    p1 = "Max";
    printf("%s %s\n", p1, p2);
    return 0;
}

A. India Max
B. Max India
C. India India
D. Max Max

34. 

What will be the output of the program ?

#include<stdio.h>
#include<string.h>

int main()
{
    printf("%c\n", "abcdefgh"[4]);
    return 0;
}

A. Error
B. d
C. e
D. abcdefgh

35. 

What will be the output of the following program in 16 bit platform assuming that 1022 is memory address of the string "Hello1" (in Turbo C under DOS) ?

#include<stdio.h>

int main()
{
    printf("%u %s\n", &"Hello1", &"Hello2");
    return 0;
}

A. 1022 Hello2
B. Hello1 1022
C. Hello1 Hello2
D. 1022 1022