Top

Control Instructions

31.

A labeled statement consist of an identifier followed by

Answer: B

No answer description available for this question.
 

Enter details here

32.

goto can be used to jump from main to within a function?

Answer: B

No answer description available for this question.
 

Enter details here

33.

What is the output of this C code?

int main()

    {

        int *p = NULL;

        for (foo(); p; p = 0)

            printf("In for loop\n");

            printf("After loop\n");

    }

 

Answer: B

No answer description available for this question

Enter details here

34.

In the following loop construct, which one is executed only once always.    for(exp1; exp2; exp3)

Answer: A

No answer description available for this question.
 

Enter details here

35.

What will be the output of the program?

#include
int main()
{
    int x = 3;
    float y = 3.0;
    if(x == y)
        printf("x and y are equal");
    else
        printf("x and y are not equal");
    return 0;
}

 

Answer: A

No answer description available for this question.
 

Enter details here

36.

What will be the output of the program?

#include
int main()
{
    int a=0, b=1, c=3;
    *((a) ? &b : &a) = a ? b : c;
    printf("%d, %d, %d\n", a, b, c);
    return 0;
}

 

Answer: C

No answer description available for this question.
 

Enter details here

37.

Which of the following statements are correct about the below program?

#include
int main()
{
    int i = 10, j = 20;
    if(i = 5) && if(j = 10)
        printf("Have a nice day");
    return 0;
}

 

Answer: C

No answer description available for this question.
 

Enter details here

38.

What will be the output of the program?

#include
int main()
{
    unsigned int i = 65535; /* Assume 2 byte integer*/
    while(i++ != 0)
        printf("%d",++i);
    printf("\n");
    return 0;
}

 

Answer: A

No answer description available for this question.
 

Enter details here

Answer: B

No answer description available for this question.

Enter details here

40.

What will be the output of the program?

#include
int main()
{
    int i=0;
    for(; i<=5; i++);
        printf("%d", i);
    return 0;
}

 

Answer: D

No answer description available for this question.
 

Enter details here

Loading…
Tags: Control Instructions Questions and Answers || Control Instructions MCQ Questions and Answers || Control Instructions GK Questions and Answers || Control Instructions GK MCQ Questions || Control Instructions Multiple Choice Questions and Answers || Control Instructions GK || GK on Control Instructions || C Programming Questions and Answers || C Programming MCQ Questions and Answers || C Programming GK Questions and Answers || GK on C Programming