google.com, pub-8786015629279405, DIRECT, f08c47fec0942fa0 C Programming MCQ Questions and Answers - Arithmetic Operators Quiz-6

C Programming MCQ Questions and Answers - Arithmetic Operators Quiz-6

0



1) What is the Priority among (*, /, %), (+, -) and (=) C Operators.?

A) (*, /, %) >  (+, -) < (=)

B) (*, /, %) <  (+, -) < (=)

C) (*, /, %) >  (+, -) > (=)

D) (*, /, %) <  (+, -)

(+, -) == (=)


 

C

2) What is the output of the C statement.?

int main()
{
    int a=0;
    a = 4 + 4/2*5 + 20;
    printf("%d", a);

    return 0;
}

A) 40
B) 4
C) 34
D) 54




C

3) What is the output of the C Program.?

int main()
{
    int a=0;
    a = 10 + 5 * 2 * 8 / 2 + 4;
    printf("%d", a);

    return 0;
}

A) 124
B) 54
C) 23
D) 404

 



B

4) What is the output of the C Program.?

int main()
{
    int a=0;
    a = 4 + 5/2*10 + 5;
    printf("%d", a);

    return 0;
}

A) 29
B) 5
C) 4
D) 34




A

5) What is the output of the C Program.?

int main()
{
    int a=0;
    a = 10 + 2 * 12 /(3*2) + 5;
    printf("%d", a);

    return 0;
}

A) 31
B) 19
C) 11
D) 29




B

6) What is the output of the C Program.?

int main()
{
    int a=0;
    a = 10 + 2 * 12 / 3 * 2 + 5;
    printf("%d", a);

    return 0;
}


 

A) 19
B) 31
C) 11
D) 25




B

7) What is the output of the C Program..?

int main()
{
    float a=10.0;
    a = a % 3;
    printf("%f", a);

    return 0;
}

A) 0
B) 1
C) 1.000000
D) Compiler error.




D

8) What is the output of the C Program.?

int main()
{
    float a=10.0;
    a = (int)a % 3;
    printf("%f", a);

    return 0;
}
A) 0
B) 1
C) 1.000000
D) Compiler Error.




C

9) What is the output of the C Program.?

int main()
{
    int a=0;
    a = (14%-5) - 2;
    printf("%d", a);

    return 0;
}

A) 0
B) -4
C) -2
D) 2






10) What is the output of the C Program.?

int main()
{
    int a= 3 + 5/2;
    printf("%d", a);

    return 0;
}

A) 3
B) 2
C) 5
D) Can not assign an expression to variable at the time of declaration.




C

Post a Comment

0 Comments
* Please Don't Spam Here. All the Comments are Reviewed by Admin.

Thank you for your interest 😊

We will back shortly after reviewing...

Thank you for your interest 😊

We will back shortly after reviewing...

Post a Comment (0)

#buttons=(Accept !) #days=(20)

Our website uses cookies to enhance your experience. Learn More
Accept !
To Top