250+ TOP MCQs on Mathematical Functions and Answers

tricky C Objective Questions on “Mathematical Functions”. One shall practice these tricky questions to improve their C programming skills needed for various interviews (campus interviews, walkin interviews, company interviews), placements, entrance exams and other competitive exams. These questions can be attempted by anyone focusing on learning C Programming language. They can be a beginner, fresher, engineering graduate or an experienced IT professional. Our C questions come with detailed explanation of the answers which helps in better understanding of C concepts.

Here is a listing of C Objective Questions on “Mathematical Functions” along with answers, explanations and/or solutions:

1. Which of the following mathematical function requires 2 parameter for successful function call?
a) fmod();
b) div();
c) atan2();
d) all of the mentioned
Answer: d
Clarification: None.

2. Which mathematical function among the following does NOT require int parameters?
a) div(x, y);
b) srand(x);
c) sqrt(x);
d) all of the mentioned
Answer: c
Clarification: None.

3. What will sin(x) returns?
a) sine of x where x is in radians
b) sine of x where x is in degree
c) cosine of x where x is in radians
d) cosine of x where x is in degree
Answer: a
Clarification: None.

4. What will cos(x) return?
a) sine of x where x is in radians
b) sine of x where x is in degree
c) cosine of x where x is in radians
d) cosine of x where x is in degree
Answer: c
Clarification: None.

5. What will be the output of the following C code?

  1.     #include 
  2.     #include 
  3.     void main()
  4.     {
  5.         int k = pow(2, 3);
  6.         printf("%dn", k);
  7.     }

a) 9
b) 8
c) -1
d) 6
Answer: b
Clarification: None.

6. What will be the output of the following C code?

  1.     #include 
  2.     #include 
  3.     void main()
  4.     {
  5.         int k = fabs(-87);
  6.         printf("%dn", k);
  7.     }

a) -87
b) 87
c) 78
d) error
Answer: b
Clarification: None.

7. What will be the output of the following C code?

  1.     #include 
  2.     #include 
  3.     void main()
  4.     {
  5.         int k = sqrt(-4);
  6.         printf("%dn", k);
  7.     }

a) -2
b) 2
c) Compile time error
d) NaN
Answer: d
Clarification: None.

8. Which among the following mathematical function do not have a “double” return-type?
a) srand(x);
b) ceil(x);
c) floor(x);
d) both ceil(x); and floor(x);
Answer: a
Clarification: None.

  250+ TOP MCQs on Arrays of Structures and Answers

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top